- tested sound ouput via phonon, added two sounds (still unused)
authorDavid Solbach <d@vidsolbach.de>
Fri, 15 Oct 2010 21:30:05 +0000 (23:30 +0200)
committerDavid Solbach <d@vidsolbach.de>
Fri, 15 Oct 2010 21:30:05 +0000 (23:30 +0200)
- added automatic update (polling for now)
- icon indicates game status
- small visual changes

17 files changed:
BundesligaWidget.pro
BundesligaWidget.pro.user [new file with mode: 0644]
Icons/Application/gelb.gif [new file with mode: 0644]
Icons/Application/grau.gif [new file with mode: 0644]
Icons/Application/gruen.gif [new file with mode: 0644]
Icons/Application/rot.gif [new file with mode: 0644]
resources.qrc
sounds/tor.aup [new file with mode: 0644]
sounds/tor.wav [new file with mode: 0644]
sounds/trillerpfeife.wav [new file with mode: 0644]
src/backendkicker.cpp
src/backendkicker.h
src/mainwidget.cpp
src/match.h
src/matchdaybackend.h
src/matchdaymodel.cpp
src/matchdaymodel.h

index b367705..0006098 100644 (file)
@@ -1,6 +1,7 @@
 include (./qmaemo5homescreenadaptor/qmaemo5homescreenadaptor.pri)
 
 QT += network
+QT += phonon
 
 OTHER_FILES += \
     bundesligawidget.desktop
diff --git a/BundesligaWidget.pro.user b/BundesligaWidget.pro.user
new file mode 100644 (file)
index 0000000..dc0c1de
--- /dev/null
@@ -0,0 +1,321 @@
+<!DOCTYPE QtCreatorProject>
+<qtcreator>
+ <data>
+  <variable>ProjectExplorer.Project.ActiveTarget</variable>
+  <value type="int">1</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.EditorSettings</variable>
+  <valuemap type="QVariantMap">
+   <value key="EditorConfiguration.Codec" type="QByteArray">ISO-8859-15</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.0</variable>
+  <valuemap type="QVariantMap">
+   <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Desktop</value>
+   <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Target.DesktopTarget</value>
+   <value key="ProjectExplorer.Target.ActiveBuildConfiguration" type="int">0</value>
+   <value key="ProjectExplorer.Target.ActiveRunConfiguration" type="int">0</value>
+   <valuemap key="ProjectExplorer.Target.BuildConfiguration.0" type="QVariantMap">
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">qmake</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">QtProjectManager.QMakeBuildStep</value>
+     <valuelist key="QtProjectManager.QMakeBuildStep.QMakeArguments" type="QVariantList"/>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.1" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">false</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList"/>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.BuildStepsCount" type="int">2</value>
+    <valuemap key="ProjectExplorer.BuildConfiguration.CleanStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">true</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList">
+      <value type="QString">clean</value>
+     </valuelist>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.CleanStepsCount" type="int">1</value>
+    <value key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment" type="bool">false</value>
+    <valuelist key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Debug</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration" type="int">2</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildDirectory" type="QString">/home/david/Projects/BundesligaWidget-build-desktop</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.QtVersionId" type="int">2</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.ToolChain" type="int">0</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild" type="bool">true</value>
+   </valuemap>
+   <valuemap key="ProjectExplorer.Target.BuildConfiguration.1" type="QVariantMap">
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">qmake</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">QtProjectManager.QMakeBuildStep</value>
+     <valuelist key="QtProjectManager.QMakeBuildStep.QMakeArguments" type="QVariantList"/>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.1" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">false</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList"/>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.BuildStepsCount" type="int">2</value>
+    <valuemap key="ProjectExplorer.BuildConfiguration.CleanStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">true</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList">
+      <value type="QString">clean</value>
+     </valuelist>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.CleanStepsCount" type="int">1</value>
+    <value key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment" type="bool">false</value>
+    <valuelist key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Release</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration" type="int">0</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildDirectory" type="QString">/home/david/Projects/BundesligaWidget-build-desktop</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.QtVersionId" type="int">2</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.ToolChain" type="int">0</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild" type="bool">true</value>
+   </valuemap>
+   <value key="ProjectExplorer.Target.BuildConfigurationCount" type="int">2</value>
+   <valuemap key="ProjectExplorer.Target.RunConfiguration.0" type="QVariantMap">
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">BundesligaWidget</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4RunConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.BaseEnvironmentBase" type="int">2</value>
+    <valuelist key="Qt4ProjectManager.Qt4RunConfiguration.CommandLineArguments" type="QVariantList"/>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.ProFile" type="QString">BundesligaWidget.pro</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UseDyldImageSuffix" type="bool">false</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UseTerminal" type="bool">false</value>
+    <valuelist key="Qt4ProjectManager.Qt4RunConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UserSetName" type="bool">false</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UserSetWorkingDirectory" type="bool">false</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UserWorkingDirectory" type="QString"></value>
+   </valuemap>
+   <value key="ProjectExplorer.Target.RunConfigurationCount" type="int">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.1</variable>
+  <valuemap type="QVariantMap">
+   <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Maemo</value>
+   <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Target.MaemoDeviceTarget</value>
+   <value key="ProjectExplorer.Target.ActiveBuildConfiguration" type="int">0</value>
+   <value key="ProjectExplorer.Target.ActiveRunConfiguration" type="int">0</value>
+   <valuemap key="ProjectExplorer.Target.BuildConfiguration.0" type="QVariantMap">
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">qmake</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">QtProjectManager.QMakeBuildStep</value>
+     <valuelist key="QtProjectManager.QMakeBuildStep.QMakeArguments" type="QVariantList"/>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.1" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">false</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList"/>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.2" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString"></value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MaemoPackageCreationStep</value>
+     <valuelist key="Qt4ProjectManager.BuildStep.MaemoPackage.LocalFiles" type="QVariantList">
+      <value type="QString">/home/david/Projects/git-buliscores/bundesligawidget.desktop</value>
+      <value type="QString">/home/david/Projects/git-buliscores/sounds/trillerpfeife.wav</value>
+      <value type="QString">/home/david/Projects/git-buliscores/sounds/tor.wav</value>
+     </valuelist>
+     <value key="Qt4ProjectManager.BuildStep.MaemoPackage.Modified" type="bool">false</value>
+     <value key="Qt4ProjectManager.BuildStep.MaemoPackage.RemoteExe" type="QString">/usr/lib/hildon-desktop/BundesligaWidget</value>
+     <valuelist key="Qt4ProjectManager.BuildStep.MaemoPackage.RemoteFiles" type="QVariantList">
+      <value type="QString">/usr/share/applications/hildon-home/bundesligawidget.desktop</value>
+      <value type="QString">/usr/share/buliscores/trillerpfeife.wav</value>
+      <value type="QString">/usr/share/buliscores/tor.wav</value>
+     </valuelist>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.BuildStepsCount" type="int">3</value>
+    <valuemap key="ProjectExplorer.BuildConfiguration.CleanStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">true</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList">
+      <value type="QString">clean</value>
+     </valuelist>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.CleanStepsCount" type="int">1</value>
+    <value key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment" type="bool">false</value>
+    <valuelist key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Debug</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration" type="int">2</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildDirectory" type="QString">/home/david/Projects/BundesligaWidget-build-maemo</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.QtVersionId" type="int">11</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.ToolChain" type="int">9</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild" type="bool">true</value>
+   </valuemap>
+   <valuemap key="ProjectExplorer.Target.BuildConfiguration.1" type="QVariantMap">
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">qmake</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">QtProjectManager.QMakeBuildStep</value>
+     <valuelist key="QtProjectManager.QMakeBuildStep.QMakeArguments" type="QVariantList"/>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.1" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">false</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList"/>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.2" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString"></value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MaemoPackageCreationStep</value>
+     <valuelist key="Qt4ProjectManager.BuildStep.MaemoPackage.LocalFiles" type="QVariantList"/>
+     <value key="Qt4ProjectManager.BuildStep.MaemoPackage.Modified" type="bool">true</value>
+     <value key="Qt4ProjectManager.BuildStep.MaemoPackage.RemoteExe" type="QString"></value>
+     <valuelist key="Qt4ProjectManager.BuildStep.MaemoPackage.RemoteFiles" type="QVariantList"/>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.BuildStepsCount" type="int">3</value>
+    <valuemap key="ProjectExplorer.BuildConfiguration.CleanStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">true</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList">
+      <value type="QString">clean</value>
+     </valuelist>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.CleanStepsCount" type="int">1</value>
+    <value key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment" type="bool">false</value>
+    <valuelist key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Release</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration" type="int">0</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildDirectory" type="QString">/home/david/Projects/BundesligaWidget-build-maemo</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.QtVersionId" type="int">11</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.ToolChain" type="int">9</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild" type="bool">true</value>
+   </valuemap>
+   <value key="ProjectExplorer.Target.BuildConfigurationCount" type="int">2</value>
+   <valuemap key="ProjectExplorer.Target.RunConfiguration.0" type="QVariantMap">
+    <value key=".ProFile" type="QString">BundesligaWidget.pro</value>
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">New Maemo Run Configuration</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MaemoRunConfiguration</value>
+    <valuelist key="Qt4ProjectManager.MaemoRunConfiguration.Arguments" type="QVariantList"/>
+    <valuemap key="Qt4ProjectManager.MaemoRunConfiguration.DebuggingHelpersLastDeployed" type="QVariantMap">
+     <value key="192.168.2.102" type="QDateTime">2010-10-09T11:30:33</value>
+    </valuemap>
+    <value key="Qt4ProjectManager.MaemoRunConfiguration.DeviceId" type="qulonglong">1</value>
+    <valuemap key="Qt4ProjectManager.MaemoRunConfiguration.LastDeployed" type="QVariantMap">
+     <value key="192.168.2.102" type="QDateTime">2010-10-15T23:23:32</value>
+    </valuemap>
+   </valuemap>
+   <value key="ProjectExplorer.Target.RunConfigurationCount" type="int">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Target.2</variable>
+  <valuemap type="QVariantMap">
+   <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Qt Simulator</value>
+   <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Target.QtSimulatorTarget</value>
+   <value key="ProjectExplorer.Target.ActiveBuildConfiguration" type="int">0</value>
+   <value key="ProjectExplorer.Target.ActiveRunConfiguration" type="int">0</value>
+   <valuemap key="ProjectExplorer.Target.BuildConfiguration.0" type="QVariantMap">
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">qmake</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">QtProjectManager.QMakeBuildStep</value>
+     <valuelist key="QtProjectManager.QMakeBuildStep.QMakeArguments" type="QVariantList"/>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.1" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">false</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList"/>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.BuildStepsCount" type="int">2</value>
+    <valuemap key="ProjectExplorer.BuildConfiguration.CleanStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">true</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList">
+      <value type="QString">clean</value>
+     </valuelist>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.CleanStepsCount" type="int">1</value>
+    <value key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment" type="bool">false</value>
+    <valuelist key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Debug</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration" type="int">2</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildDirectory" type="QString">/home/david/Projects/BundesligaWidget-build-simulator</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.QtVersionId" type="int">4</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.ToolChain" type="int">0</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild" type="bool">true</value>
+   </valuemap>
+   <valuemap key="ProjectExplorer.Target.BuildConfiguration.1" type="QVariantMap">
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">qmake</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">QtProjectManager.QMakeBuildStep</value>
+     <valuelist key="QtProjectManager.QMakeBuildStep.QMakeArguments" type="QVariantList"/>
+    </valuemap>
+    <valuemap key="ProjectExplorer.BuildConfiguration.BuildStep.1" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">false</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList"/>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.BuildStepsCount" type="int">2</value>
+    <valuemap key="ProjectExplorer.BuildConfiguration.CleanStep.0" type="QVariantMap">
+     <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Make</value>
+     <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.MakeStep</value>
+     <value key="Qt4ProjectManager.MakeStep.Clean" type="bool">true</value>
+     <valuelist key="Qt4ProjectManager.MakeStep.MakeArguments" type="QVariantList">
+      <value type="QString">clean</value>
+     </valuelist>
+     <value key="Qt4ProjectManager.MakeStep.MakeCommand" type="QString"></value>
+    </valuemap>
+    <value key="ProjectExplorer.BuildConfiguration.CleanStepsCount" type="int">1</value>
+    <value key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment" type="bool">false</value>
+    <valuelist key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">Release</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4BuildConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration" type="int">0</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.BuildDirectory" type="QString">/home/david/Projects/BundesligaWidget-build-simulator</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.QtVersionId" type="int">4</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.ToolChain" type="int">0</value>
+    <value key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild" type="bool">true</value>
+   </valuemap>
+   <value key="ProjectExplorer.Target.BuildConfigurationCount" type="int">2</value>
+   <valuemap key="ProjectExplorer.Target.RunConfiguration.0" type="QVariantMap">
+    <value key="ProjectExplorer.ProjectConfiguration.DisplayName" type="QString">BundesligaWidget</value>
+    <value key="ProjectExplorer.ProjectConfiguration.Id" type="QString">Qt4ProjectManager.Qt4RunConfiguration</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.BaseEnvironmentBase" type="int">2</value>
+    <valuelist key="Qt4ProjectManager.Qt4RunConfiguration.CommandLineArguments" type="QVariantList"/>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.ProFile" type="QString">BundesligaWidget.pro</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UseDyldImageSuffix" type="bool">false</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UseTerminal" type="bool">false</value>
+    <valuelist key="Qt4ProjectManager.Qt4RunConfiguration.UserEnvironmentChanges" type="QVariantList"/>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UserSetName" type="bool">false</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UserSetWorkingDirectory" type="bool">false</value>
+    <value key="Qt4ProjectManager.Qt4RunConfiguration.UserWorkingDirectory" type="QString"></value>
+   </valuemap>
+   <value key="ProjectExplorer.Target.RunConfigurationCount" type="int">1</value>
+  </valuemap>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.TargetCount</variable>
+  <value type="int">3</value>
+ </data>
+ <data>
+  <variable>ProjectExplorer.Project.Updater.FileVersion</variable>
+  <value type="int">4</value>
+ </data>
+</qtcreator>
diff --git a/Icons/Application/gelb.gif b/Icons/Application/gelb.gif
new file mode 100644 (file)
index 0000000..0918692
Binary files /dev/null and b/Icons/Application/gelb.gif differ
diff --git a/Icons/Application/grau.gif b/Icons/Application/grau.gif
new file mode 100644 (file)
index 0000000..29a50e0
Binary files /dev/null and b/Icons/Application/grau.gif differ
diff --git a/Icons/Application/gruen.gif b/Icons/Application/gruen.gif
new file mode 100644 (file)
index 0000000..924e5e0
Binary files /dev/null and b/Icons/Application/gruen.gif differ
diff --git a/Icons/Application/rot.gif b/Icons/Application/rot.gif
new file mode 100644 (file)
index 0000000..991b8fd
Binary files /dev/null and b/Icons/Application/rot.gif differ
index 7bbfdf3..a6aedd9 100644 (file)
         <file>Icons/St.Pauli.png</file>
         <file>Icons/Stuttgart.png</file>
         <file>Icons/Wolfsburg.png</file>
+        <file>sounds/tor.wav</file>
+        <file>sounds/trillerpfeife.wav</file>
+        <file alias="bullet-yellow">Icons/Application/gelb.gif</file>
+        <file alias="bullet-grey">Icons/Application/grau.gif</file>
+        <file alias="bullet-green">Icons/Application/gruen.gif</file>
+        <file alias="bullet-red">Icons/Application/rot.gif</file>
     </qresource>
 </RCC>
diff --git a/sounds/tor.aup b/sounds/tor.aup
new file mode 100644 (file)
index 0000000..0e113d4
--- /dev/null
@@ -0,0 +1,39 @@
+<?xml version="1.0" standalone="no" ?>
+<!DOCTYPE project PUBLIC "-//audacityproject-1.3.0//DTD//EN" "http://audacity.sourceforge.net/xml/audacityproject-1.3.0.dtd" >
+<project xmlns="http://audacity.sourceforge.net/xml/" projname="tor_data" version="1.3.0" audacityversion="1.3.12-beta" sel0="3.6859179168" sel1="14.4739678035" vpos="0" h="0.0000000000" zoom="11.1234164529" rate="44100">
+       <tags>
+               <tag name="id3v2" value="1"/>
+       </tags>
+       <wavetrack name="tor 1" channel="0" linked="1" mute="0" solo="0" height="150" minimized="0" rate="44100" gain="1" pan="0">
+               <waveclip offset="3.68591792">
+                       <sequence maxsamples="262144" sampleformat="262159" numsamples="475753">
+                               <waveblock start="0">
+                                       <simpleblockfile filename="e00009b4.au" len="143837" min="-0.931901" max="0.922553" rms="0.201551"/>
+                               </waveblock>
+                               <waveblock start="143837">
+                                       <simpleblockfile filename="e0000bae.au" len="143837" min="-0.774588" max="0.69488" rms="0.154483"/>
+                               </waveblock>
+                               <waveblock start="287674">
+                                       <simpleblockfile filename="e0000969.au" len="188079" min="-0.527986" max="0.472197" rms="0.088599"/>
+                               </waveblock>
+                       </sequence>
+                       <envelope numpoints="0"/>
+               </waveclip>
+       </wavetrack>
+       <wavetrack name="tor" channel="1" linked="0" mute="0" solo="0" height="150" minimized="0" rate="44100" gain="1" pan="0">
+               <waveclip offset="3.68591792">
+                       <sequence maxsamples="262144" sampleformat="262159" numsamples="475753">
+                               <waveblock start="0">
+                                       <simpleblockfile filename="e0000c5b.au" len="143837" min="-0.963046" max="0.998089" rms="0.238058"/>
+                               </waveblock>
+                               <waveblock start="143837">
+                                       <simpleblockfile filename="e0000c6f.au" len="143837" min="-0.856642" max="0.826671" rms="0.185497"/>
+                               </waveblock>
+                               <waveblock start="287674">
+                                       <simpleblockfile filename="e0000810.au" len="188079" min="-0.563311" max="0.579272" rms="0.107539"/>
+                               </waveblock>
+                       </sequence>
+                       <envelope numpoints="0"/>
+               </waveclip>
+       </wavetrack>
+</project>
diff --git a/sounds/tor.wav b/sounds/tor.wav
new file mode 100644 (file)
index 0000000..9117fc9
Binary files /dev/null and b/sounds/tor.wav differ
diff --git a/sounds/trillerpfeife.wav b/sounds/trillerpfeife.wav
new file mode 100644 (file)
index 0000000..e79ae58
Binary files /dev/null and b/sounds/trillerpfeife.wav differ
index d2914aa..f6a1a6d 100644 (file)
 
 #include "backendkicker.h"
 
+const int BackendKicker::INTERVAL_FAST = 100 * 1000;
+const int BackendKicker::INTERVAL_SLOW = 3600 * 1000;
+
 BackendKicker::BackendKicker(QObject *parent) :
-    MatchDayBackend(parent)
+    MatchDayBackend(parent),
+    m_updateTimer(this),
+    m_netaccmgr(new QNetworkAccessManager(this))
 {
     QSettings settings(qApp->organizationName(), qApp->applicationName());
+
     this->selectLeague(settings.value("League", "1. Bundesliga").toString());
 
+    connect(m_netaccmgr, SIGNAL(finished(QNetworkReply*)),
+            this, SLOT(dlndFinished(QNetworkReply*)));
+
+    connect(&m_updateTimer, SIGNAL(timeout()),
+            this, SLOT(update()));
+
     this->update();
 }
 
@@ -56,7 +68,7 @@ static QDateTime parseDate(QString datehtml)
     tokens = datehtml.split(QRegExp("[>.&;:<\"]"), QString::SkipEmptyParts);
     date = QDate::currentDate();
 
-    qDebug() << tokens;
+    //qDebug() << tokens;
     if (tokens.count() < 6) {
         return lastParsedDate;
     }
@@ -81,7 +93,7 @@ static QString parseTeam(QString teamhtml)
     teamhtml.truncate(teamhtml.indexOf("</a>"));
     team = teamhtml.mid(teamhtml.lastIndexOf(">") + 1);
 
-    qDebug() << "parseTeam out: " << team;
+    //qDebug() << "parseTeam out: " << team;
     return team;
 }
 
@@ -89,9 +101,9 @@ static void parseScore(Match* match, QString scorehtml)
 {
     QStringList tokens;
 
-    qDebug() << "parseScore in: " << scorehtml;
+    //qDebug() << "parseScore in: " << scorehtml;
     tokens = scorehtml.split(QRegExp("[>&();:<]"), QString::SkipEmptyParts);
-    qDebug() << tokens;
+    //qDebug() << tokens;
 
     if (tokens.count() == 7) {
         // no extra color tag -> either not started, halftime or finished
@@ -122,9 +134,9 @@ static void parseScore(Match* match, QString scorehtml)
         }
 
     }
-    qDebug() << "match state: " << match->state();
-    qDebug() << "match home: " << match->homeScore();
-    qDebug() << "match away: " << match->awayScore();
+//    qDebug() << "match state: " << match->state();
+//    qDebug() << "match home: " << match->homeScore();
+//    qDebug() << "match away: " << match->awayScore();
 }
 
 void BackendKicker::parsePage (QString htmlstr)
@@ -145,7 +157,7 @@ void BackendKicker::parsePage (QString htmlstr)
     while ((pos = rx.indexIn(htmlstr, pos)) != -1) {
          ++count;
          rawmatches.append(htmlstr.mid(pos, rx.matchedLength()));
-         qDebug() << "MATCH " << count << ":" << htmlstr.mid(pos, rx.matchedLength()) << "\n\n";
+         //qDebug() << "MATCH " << count << ":" << htmlstr.mid(pos, rx.matchedLength()) << "\n\n";
          pos += rx.matchedLength();
      }
 
@@ -200,15 +212,16 @@ bool BackendKicker::selectLeague(QString league)
 
 void BackendKicker::update()
 {
-    emit updateStarted();
+    if (matchRunning()) {
+        m_updateTimer.start(INTERVAL_FAST);
+    } else {
+        m_updateTimer.start(INTERVAL_SLOW);
+    }
 
-    //QString URL = "file:///home/david/Projects/git-buliscores/testdata/spieltag.html";
-    QNetworkAccessManager *manager = new QNetworkAccessManager(this);
-    connect(manager, SIGNAL(finished(QNetworkReply*)),
-            this, SLOT(dlndFinished(QNetworkReply*)));
+    emit updateStarted();
 
-    qDebug() << "URL: " << m_URL;
-    manager->get(QNetworkRequest(QUrl(m_URL)));
+    //qDebug() << "URL: " << m_URL;
+    m_netaccmgr->get(QNetworkRequest(QUrl(m_URL)));
 }
 
 void BackendKicker::dlndFinished(QNetworkReply *reply)
@@ -227,3 +240,29 @@ void BackendKicker::dlndFinished(QNetworkReply *reply)
 
     emit matchListChanged();
 }
+
+bool BackendKicker::matchRunning()
+{
+    QListIterator<Match*> iter(m_matchlist);
+    Match*        match;
+    bool          matchrunning = false;
+    int           secstogame;
+
+    while (iter.hasNext()) {
+        match = iter.next();
+        if (match->state() == Match::FirstHalf ||
+            match->state() == Match::SecondHalf) {
+
+            matchrunning = true;
+            break;
+        } else {
+            secstogame = QDateTime::currentDateTime().secsTo(match->date());
+            if (secstogame >= 0 && secstogame < INTERVAL_SLOW) {
+                matchrunning = true;
+                break;
+            }
+        }
+    }
+
+    return matchrunning;
+}
index 679fef8..8b1a9a6 100644 (file)
@@ -2,6 +2,8 @@
 #define BACKENDKICKER_H
 
 #include <QObject>
+#include <QTimer>
+#include <QNetworkAccessManager>
 #include <QNetworkReply>
 
 #include "matchdaybackend.h"
@@ -9,12 +11,6 @@
 class BackendKicker : public MatchDayBackend
 {
     Q_OBJECT
-private:
-    QList<Match*> m_matchlist;
-    QString       m_URL;
-
-    void parsePage (QString htmlstr);
-
 public:
     explicit BackendKicker(QObject *parent = 0);
 
@@ -22,16 +18,32 @@ public:
     QList<Match*> matchList();
 
     bool          selectLeague(QString league);
+    void          setAutomaticUpdate(bool);
 
 signals:
     void matchListChanged(void);
     void updateStarted(void);
 
+public slots:
+    void update();
+
+private:
+    QList<Match*> m_matchlist;
+    QString       m_URL;
+    QDateTime     m_lastUpdate;
+    QTimer        m_updateTimer;
+    QNetworkAccessManager* m_netaccmgr;
+
+    static const int INTERVAL_FAST;
+    static const int INTERVAL_SLOW;
+
+    void parsePage (QString htmlstr);
+    bool matchRunning (void);
+
 private slots:
     void dlndFinished(QNetworkReply *reply);
 
-public slots:
-    void update();
+
 };
 
 #endif // BACKENDKICKER_H
index f25f7e1..dbffeee 100644 (file)
@@ -1,6 +1,9 @@
 #include <QSettings>
 #include <QMouseEvent>
 #include <QApplication>
+#include <QProcess>
+#include <phonon/AudioOutput>
+#include <phonon/MediaObject>
 
 #include "mainwidget.h"
 #include "backendkicker.h"
@@ -18,10 +21,12 @@ MainWidget::MainWidget(QWidget *parent) :
     QFont f;
     QPalette palette;
 
+    // label
+    m_statuslbl.setText(tr("BuLi Scores!"));
     f.setPixelSize(40);
     palette.setColor(QPalette::Background, QColor(0, 0, 0, 127));
     palette.setColor(QPalette::Foreground, QColor(255, 255, 255, 127));
-    m_statuslbl.hide();
+    m_statuslbl.show();
     m_statuslbl.setPalette(palette);
     m_statuslbl.setAttribute(Qt::WA_TransparentForMouseEvents);
     m_statuslbl.setAutoFillBackground(true);
@@ -30,13 +35,20 @@ MainWidget::MainWidget(QWidget *parent) :
 
     m_statuslbl.setFont(f);
 
+    // table
+    m_scoretbl->hide();
+
     this->setAttribute(Qt::WA_TranslucentBackground);
 
     this->setLayout(&m_layout);
-
     m_layout.addWidget(&m_statuslbl);
     m_layout.addWidget(m_scoretbl);
 
+    // sounds
+    Phonon::MediaObject *m_mediaObject = new Phonon::MediaObject(this);
+    Phonon::AudioOutput *m_audioOutput =  new Phonon::AudioOutput(Phonon::MusicCategory, this);
+    Phonon::createPath(m_mediaObject, m_audioOutput);
+
     connect(m_settingsdlg, SIGNAL(accepted()),
             this, SLOT(update()));
 
@@ -70,6 +82,8 @@ void MainWidget::onBackendUpdateStarted()
 
 void MainWidget::onBackendUpdateFinished()
 {
+    //mediaObject->play();
+
     m_scoretbl->show();
     m_statuslbl.hide();
 }
index 38c1f72..081e174 100644 (file)
@@ -69,6 +69,7 @@ public:
 
 signals:
     void scoreChanged(int homescore, int awayscore);
+    void stateChanged(MatchState state);
 
 
 public slots:
index 51a4a11..7944e5d 100644 (file)
@@ -21,7 +21,6 @@ public:
     virtual QList<Match*> matchList() = 0;
 
     virtual bool selectLeague(QString league) = 0;
-    virtual bool setAutomaticUpdate(bool) = 0;
 
 signals:
     void matchListChanged(void);
index 901a5d2..0ebb41c 100644 (file)
@@ -30,7 +30,7 @@ int MatchDayModel::rowCount(const QModelIndex&) const
 
 int MatchDayModel::columnCount(const QModelIndex&) const
 {
-    return 8;
+    return 10;
 }
 
 QVariant MatchDayModel::data(const QModelIndex& index, int role) const
@@ -40,8 +40,6 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
     QSize        s;
     QIcon        i;
 
-    f.setPixelSize(14);
-
     if ((match = m_backend->matchList().at(index.row())) == NULL) {
         return QVariant(QVariant::Invalid);
     }
@@ -49,7 +47,7 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
     // DisplayRole
     switch (role) {
     case Qt::BackgroundRole:
-        return QBrush(QColor(0, 0, 0, 100));
+        return QBrush(QColor(20, 20, 20, 100));
         break;
     case Qt::DecorationRole:
         switch (index.column()) {
@@ -59,8 +57,25 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
         case HomeIcon:
             i = match->homeEmblem().pixmap(25,25);
             break;
-        case Seperator:
-            i = QIcon(":/Icons/Application/football.png").pixmap(20,20);
+        case MatchState:
+            switch(match->state()) {
+            case Match::NotStarted:
+                return QIcon(":/bullet-grey").pixmap(15,15);
+                break;
+            case Match::FirstHalf:
+            case Match::SecondHalf:
+                return QIcon(":/bullet-green").pixmap(15,15);
+                break;
+            case Match::HalfTime:
+                return QIcon(":/bullet-yellow").pixmap(15,15);
+                break;
+            case Match::Finished:
+                return QIcon(":/bullet-red").pixmap(15,15);
+                break;
+            default:
+                return QVariant(QVariant::Invalid);
+            }
+
             break;
         }
         return i;
@@ -68,9 +83,6 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
 
     case Qt::DisplayRole:
         switch (index.column()) {
-        case AwayIcon:
-            return match->awayEmblem();
-            break;
         case AwayTeam:
             return match->awayTeam();
             break;
@@ -81,9 +93,6 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
                 return match->awayScore();
             }
             break;
-        case HomeIcon:
-            return match->homeEmblem();
-            break;
         case HomeTeam:
             return match->homeTeam();
             break;
@@ -94,9 +103,13 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
                 return match->homeScore();
             }
             break;
+        case Seperator:
+            return ":";
+            break;
         case Date:
-            return match->date().toString("ddd hh mm");
+            return match->date().toString("ddd hh:mm");
             break;
+
         default:
             return QVariant(QVariant::Invalid);
             break;
@@ -106,6 +119,12 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
     case Qt::SizeHintRole:
         s.setHeight(25);
         switch (index.column()) {
+        case Spacer:
+            s.setWidth(3);
+            break;
+        case MatchState:
+            s.setWidth(15);
+            break;
         case AwayIcon:
             s.setWidth(29);
             break;
@@ -125,7 +144,7 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
             s.setWidth(4);
             break;
         case Seperator:
-            s.setWidth(3);
+            s.setWidth(5);
             break;
         case Date:
             s.setWidth(75);
@@ -138,16 +157,17 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
         break;
 
     case Qt::TextAlignmentRole:
-        if (index.column() < 3) {
+        if (index.column() < Seperator) {
             return 0x0002 | 0x0080;
-        } else if (index.column() > 3) {
+        } else if (index.column() > Seperator) {
             return 0x0001 | 0x0080;
         } else {
             return Qt::AlignCenter;
         }
         break;
-    case Qt::FontRole:
 
+    case Qt::FontRole:
+        f.setPixelSize(14);
 
         return f;
 
@@ -163,14 +183,14 @@ QVariant MatchDayModel::data(const QModelIndex& index, int role) const
 void MatchDayModel::onMatchListChanged(void)
 {
     //remove all rows
-    qDebug() << "beginRemoveRows: " << 0 << ", " << rowCount(QModelIndex()) - 1;
+    //qDebug() << "beginRemoveRows: " << 0 << ", " << rowCount(QModelIndex()) - 1;
     beginRemoveRows(QModelIndex(),
                     0,
                     m_lastRowCount);
     endRemoveRows();
 
     //add rows
-    qDebug() << "beginInsertRows: " << 0 << ", " << m_backend->matchList().count() - 1;
+    //qDebug() << "beginInsertRows: " << 0 << ", " << m_backend->matchList().count() - 1;
     beginInsertRows(QModelIndex(),
                     0,
                     m_backend->matchList().count() - 1);
@@ -179,7 +199,7 @@ void MatchDayModel::onMatchListChanged(void)
     m_lastRowCount = m_backend->matchList().count() - 1;
 
     // invalidate complete data
-    qDebug() << "rowCount @ emit dataChanged: " << rowCount(QModelIndex());
+    //qDebug() << "rowCount @ emit dataChanged: " << rowCount(QModelIndex());
     emit dataChanged(index(0, 0),
                      index(rowCount(QModelIndex()) - 1, columnCount(QModelIndex()) - 1));
 
index 228ba2d..0c9ec95 100644 (file)
@@ -12,14 +12,16 @@ class MatchDayModel : public QAbstractTableModel
     Q_OBJECT
 
     enum {
-        HomeIcon  = 0,
-        HomeTeam  = 1,
-        HomeScore = 2,
-        Seperator = 3,
-        AwayScore = 4,
-        AwayTeam  = 5,
-        AwayIcon  = 6,
-        Date      = 7
+        Spacer = 0,
+        MatchState,
+        HomeIcon,
+        HomeTeam,
+        HomeScore,
+        Seperator,
+        AwayScore,
+        AwayTeam,
+        AwayIcon,
+        Date
     };
 
 private: