[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: branches/work/soc-parley/parley/practice
From: David Capel <wot.narg () gmail ! com>
Date: 2008-05-30 16:27:36
Message-ID: 1212164856.750558.31207.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 814544 by capel:
Replaced std::shuffle with KRandomSequence
M +1 -1 parleypracticemainwindow.cpp
M +2 -3 testentrymanager.cpp
--- branches/work/soc-parley/parley/practice/parleypracticemainwindow.cpp #814543:814544
@@ -239,7 +239,7 @@
double x = (width() - side / 2);
double y = (height() - side / 2);
m_view->scale(side / 600.0, side / 600.0);
- m_view->setViewport(x, y, side, side);
+// m_view->setViewport(x, y, side, side);
return QObject::eventFilter(obj, event);
}
if (event->type() == QEvent::MouseButtonPress && false)
--- branches/work/soc-parley/parley/practice/testentrymanager.cpp #814543:814544
@@ -20,7 +20,7 @@
***************************************************************************/
-#include <algorithm>
+#include <KRandomSequence>
#include "practiceprefs.h"
@@ -91,8 +91,7 @@
void TestEntryManager::shuffle()
{
kDebug() << "called";
- // The stl random_shuffle is better than what I would write ;)
- std::random_shuffle(m_entries.begin(), m_entries.end());
+ KRandomSequence().randomize(m_entries);
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic