Changeset View
Changeset View
Standalone View
Standalone View
src/gui/ksudokugame.cpp
Show All 29 Lines | |||||
30 | 30 | | |||
31 | #include <KMessageBox> | 31 | #include <KMessageBox> | ||
32 | #include <KLocalizedString> | 32 | #include <KLocalizedString> | ||
33 | 33 | | |||
34 | #include <QList> | 34 | #include <QList> | ||
35 | 35 | | |||
36 | #include <QDebug> // IDW | 36 | #include <QDebug> // IDW | ||
37 | 37 | | |||
38 | #include <kurl.h> | 38 | #include <QUrl> | ||
39 | 39 | | |||
40 | class QWidget; | 40 | class QWidget; | ||
41 | 41 | | |||
42 | namespace ksudoku { | 42 | namespace ksudoku { | ||
43 | 43 | | |||
44 | /** | 44 | /** | ||
45 | * @TODO replace m_refCount with QAtomic (in KDE4 version) | 45 | * @TODO replace m_refCount with QAtomic (in KDE4 version) | ||
46 | */ | 46 | */ | ||
Show All 29 Lines | 75 | public: | |||
76 | PuzzleState state; | 76 | PuzzleState state; | ||
77 | 77 | | |||
78 | bool hadHelp : 1; | 78 | bool hadHelp : 1; | ||
79 | bool wasFinished : 1; | 79 | bool wasFinished : 1; | ||
80 | 80 | | |||
81 | Puzzle* puzzle; | 81 | Puzzle* puzzle; | ||
82 | QTime time; | 82 | QTime time; | ||
83 | int accumTime; | 83 | int accumTime; | ||
84 | KUrl url; | 84 | QUrl url; | ||
85 | QList<HistoryEvent> history; | 85 | QList<HistoryEvent> history; | ||
86 | int historyPos; | 86 | int historyPos; | ||
87 | 87 | | |||
88 | QVector<int> m_cage; | 88 | QVector<int> m_cage; | ||
89 | int m_cageValue; | 89 | int m_cageValue; | ||
90 | CageOperator m_cageOperator; | 90 | CageOperator m_cageOperator; | ||
91 | int m_currentCageSaved; | 91 | int m_currentCageSaved; | ||
92 | QWidget * m_messageParent; | 92 | QWidget * m_messageParent; | ||
▲ Show 20 Lines • Show All 120 Lines • ▼ Show 20 Line(s) | 212 | GameIFace* Game::interface() const { | |||
213 | return m_private; | 213 | return m_private; | ||
214 | } | 214 | } | ||
215 | 215 | | |||
216 | Puzzle* Game::puzzle() const { | 216 | Puzzle* Game::puzzle() const { | ||
217 | if(!m_private) return 0; | 217 | if(!m_private) return 0; | ||
218 | return m_private->puzzle; | 218 | return m_private->puzzle; | ||
219 | } | 219 | } | ||
220 | 220 | | |||
221 | void Game::setUrl(const KUrl& url) { | 221 | void Game::setUrl(const QUrl& url) { | ||
222 | if(!m_private) return; | 222 | if(!m_private) return; | ||
223 | 223 | | |||
224 | m_private->url = url; | 224 | m_private->url = url; | ||
225 | } | 225 | } | ||
226 | 226 | | |||
227 | KUrl Game::getUrl() const { | 227 | QUrl Game::getUrl() const { | ||
228 | if(!m_private) return KUrl(); | 228 | if(!m_private) return QUrl(); | ||
229 | return m_private->url; | 229 | return m_private->url; | ||
230 | } | 230 | } | ||
231 | 231 | | |||
232 | 232 | | |||
233 | void Game::setGiven(int index, bool given) { | 233 | void Game::setGiven(int index, bool given) { | ||
234 | if(!m_private) return; | 234 | if(!m_private) return; | ||
235 | 235 | | |||
236 | if(given != m_private->state.given(index)) { | 236 | if(given != m_private->state.given(index)) { | ||
▲ Show 20 Lines • Show All 547 Lines • Show Last 20 Lines |