[9175b5]: xbmc / Application.h  Maximize  Restore  History

Repo status: analyzing...

Download this file

241 lines (231 with data), 9.0 kB

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
#pragma once
#include <xtl.h>
#include <xgraphics.h>
#include <stdio.h>
#include <vector>
#include <memory>
#include <stdlib.h>
#include "xbapplicationex.h"
#include "applicationmessenger.h"
#include "GUIWindowManager.h"
#include "guiwindow.h"
#include "GUIMessage.h"
#include "GUIButtonControl.h"
#include "GUIImage.h"
#include "GUIFontManager.h"
#include "SkinInfo.h"
#include "key.h"
#include "utils/imdb.h"
#include "GUIWindowHome.h"
#include "GUIWindowPrograms.h"
#include "GUIWindowSettingsPrograms.h"
#include "GUIWindowPictures.h"
#include "GUIWindowMyFiles.h"
#include "GUIWindowVideo.h"
#include "GUIWindowVideoGenre.h"
#include "GUIWindowVideoActors.h"
#include "GUIWindowVideoYear.h"
#include "GUIWindowVideoTitle.h"
#include "GUIWindowSettings.h"
#include "GUIDialogInvite.h"
#include "GUIDialogKeyboard.h"
#include "GUIDialogYesNo.h"
#include "GUIDialogOK.h"
#include "GUIDialogProgress.h"
#include "GUIDialogSelect.h"
#include "GUIDialogFileStacking.h"
#include "GUIWindowSystemInfo.h"
#include "GUIWindowSettingsLCD.h"
#include "GUIWindowSettingsGeneral.h"
//#include "GUIWindowSettingsScreen.h"
#include "GUIWindowSettingsMyVideo.h"
#include "GUIWindowSettingsUICalibration.h"
#include "GUIWindowSettingsScreenCalibration.h"
#include "GUIWindowSettingsSubtitles.h"
#include "GUIWindowScreensaver.h" // CB: Matrix Screensaver
#include "GUIWindowOSD.h"
#include "GUIWindowMusicInfo.h"
#include "GUIWindowVideoInfo.h"
#include "GUIWindowScriptsInfo.h"
#include "GUIWindowMusicOverlay.h"
#include "GUIWindowFullScreen.h"
#include "GUIWindowVideoOverlay.h"
#include "GUIWindowVideoPlaylist.h"
#include "GUIWindowSettingsSlideShow.h"
#include "GUIWindowSettingsScreensaver.h"
#include "GUIWindowSettingsCDRipper.h"
#include "guiwindowsettingsautorun.h"
#include "guiwindowsettingsfilter.h"
//#include "guiwindowsettingsmusic.h"
#include "GUIWindowSettingsMyMusic.h"
#include "GUIWindowScripts.h"
#include "GUIWindowVisualisation.h"
#include "GUIWindowSlideshow.h"
#include "GUIWindowMusicPlaylist.h"
#include "GUIWindowMusicSongs.h"
#include "GUIWindowMusicAlbum.h"
#include "GUIWindowMusicArtists.h"
#include "GUIWindowMusicGenres.h"
#include "GUIWindowMusicTop100.h"
#include "GUIWindowBuddies.h" //BUDDIES
#include "GUIWindowWeather.h" //WEATHER
#include "GUIWindowSettingsWeather.h" //WEATHER SETTINGS
#include "GUIWindowSettingsCache.h"
#include "LocalizeStrings.h"
#include "utils/sntp.h"
#include "utils/delaycontroller.h"
#include "keyboard/virtualkeyboard.h"
#include "lib/libPython/XBPython.h"
#include "lib/libGoAhead/webserver.h"
#include "lib/libfilezilla/xbfilezilla.h"
#include "cores/IPlayer.h"
#include "DetectDVDType.h"
#include "Autorun.h"
#include "IMsgTargetCallback.h"
#include "ButtonTranslator.h"
#include "musicInfoTag.h"
#include "GUIWindowSettingsSkinLanguage.h"
#include "GUIWindowSettingsUserInterface.h"
#include "GUIWindowSettingsAudio.h"
#include "GUIWindowSettingsSystem.h"
#include "GUIWindowSettingsProfile.h"
using namespace std;
using namespace MEDIA_DETECT;
using namespace MUSIC_INFO;
class CApplication : public CXBApplicationEx, public IPlayerCallback, public IMsgTargetCallback
{
public:
CApplication(void);
virtual ~CApplication(void);
virtual HRESULT Initialize();
virtual void FrameMove();
virtual void Render();
virtual HRESULT Create();
void StartServices();
void StopServices();
void Stop();
void LoadSkin(const CStdString& strSkin);
void DelayLoadSkin();
void CancelDelayLoadSkin();
const CStdString& CurrentFile();
virtual bool OnMessage(CGUIMessage& message);
virtual void OnPlayBackEnded();
virtual void OnPlayBackStarted();
bool PlayFile(const CStdString& strFile,bool bRestart=false);
void StopPlaying();
void Restart(bool bSamePosition=true);
void EnableOverlay();
void DisableOverlay();
bool IsPlaying() const ;
bool IsPlayingAudio() const ;
bool IsPlayingVideo() const ;
void OnKey(CKey& key);
void RenderFullScreen();
bool NeedRenderFullScreen();
bool MustBlockHDSpinDown(bool bCheckThisForNormalSpinDown = true);
void CheckNetworkHDSpinDown(bool playbackStarted = false);
void CheckHDSpindown();
void CheckScreenSaver(); // CB: SCREENSAVER PATCH
void CheckShutdown();
void SetCurrentSong(const CMusicInfoTag& tag);
void SetCurrentMovie(const CIMDBMovie& tag);
void ResetAllControls();
virtual void Process();
void ResetScreenSaver();
int GetPlaySpeed() const;
void SetPlaySpeed(int iSpeed);
bool IsButtonDown(DWORD code);
bool ResetScreenSaverWindow();
CGUIWindowHome m_guiHome;
CGUIWindowPrograms m_guiPrograms;
CGUIWindowSettingsPrograms m_guiSettingsPrograms;
CGUIWindowSettingsProfile m_guiSettingsProfile;
CGUIWindowSettingsSystem m_guiSettingsSytem;
CGUIWindowPictures m_guiPictures;
CGUIDialogInvite m_guiDialogInvite;
CGUIDialogKeyboard m_guiDialogKeyboard;
CGUIDialogYesNo m_guiDialogYesNo;
CGUIDialogProgress m_guiDialogProgress;
CGUIDialogOK m_guiDialogOK;
CGUIWindowMyFiles m_guiMyFiles;
CGUIWindowVideo m_guiMyVideo;
CGUIWindowSettings m_guiSettings;
CGUIWindowSystemInfo m_guiSystemInfo;
CGUIWindowSettingsGeneral m_guiSettingsGeneral;
CGUIWindowMusicInfo m_guiMusicInfo;
CGUIWindowVideoInfo m_guiVideoInfo;
CGUIWindowScriptsInfo m_guiScriptsInfo;
//CGUIWindowSettingsScreen m_guiSettingsScreen; // now m_guiSettingsMyVideo
CGUIWindowSettingsUICalibration m_guiSettingsUICalibration;
CGUIWindowSettingsScreenCalibration m_guiSettingsScreenCalibration;
CGUIWindowSettingsSlideShow m_guiSettingsSlideShow;
CGUIWindowSettingsScreensaver m_guiSettingsScreensaver;
CGUIWindowSettingsCDRipper m_guiSettingsCDRipper;
//CGUIWindowSettingsOSD m_guiSettingsOSD;
CGUIWindowSettingsAutoRun m_guiSettingsAutoRun;
CGUIWindowScripts m_guiScripts;
CGUIWindowSettingsFilter m_guiSettingsFilter;
CGUIDialogSelect m_guiDialogSelect;
CGUIDialogFileStacking m_guiDialogFileStacking;
CGUIWindowMusicOverlay m_guiMusicOverlay;
CGUIWindowFullScreen m_guiWindowFullScreen;
CGUIWindowVideoOverlay m_guiWindowVideoOverlay;
CGUIWindowVisualisation m_guiWindowVisualisation;
//CGUIWindowSettingsMusic m_guiSettingsMusic; // now m_guiSettingsMyMusic
CGUIWindowSlideShow m_guiWindowSlideshow;
CGUIWindowMusicPlayList m_guiMyMusicPlayList;
CGUIWindowVideoPlaylist m_guiMyVideoPlayList;
CGUIWindowMusicSongs m_guiMyMusicSongs;
CGUIWindowMusicAlbum m_guiMyMusicAlbum;
CGUIWindowMusicArtists m_guiMyMusicArtists;
CGUIWindowMusicGenres m_guiMyMusicGenres;
CGUIWindowMusicTop100 m_guiMyMusicTop100;
CGUIWindowScreensaver m_guiWindowScreensaver;
CGUIWindowSettingsLCD m_guiSettingsLCD;
CGUIWindowSettingsSubtitles m_guiSettingsSubtitles;
CGUIWindowVideoGenre m_guiVideoGenre;
CGUIWindowVideoActors m_guiVideoActors;
CGUIWindowVideoYear m_guiVideoYear;
CGUIWindowVideoTitle m_guiVideoTitle;
CGUIWindowWeather m_guiMyWeather; //WEATHER
CGUIWindowBuddies m_guiMyBuddies; //BUDDIES
CGUIWindowSettingsWeather m_guiSettingsWeather; //WEATHER SETTINGS
CGUIWindowOSD m_guiWindowOSD;
CGUIWindowSettingsCache m_guiSettingsCache;
CGUIWindowSettingsSkinLanguage m_guiSettingsSkinLanguage;
CGUIWindowSettingsUserInterface m_guiSettingsUserInterface;
CGUIWindowSettingsAudio m_guiSettingsAudio;
CGUIWindowSettingsMyVideo m_guiSettingsMyVideo;
CGUIWindowSettingsMyMusic m_guiSettingsMyMusic;
CXBVirtualKeyboard m_keyboard;
CSNTPClient m_sntpClient;
CDetectDVDMedia m_DetectDVDType;
CAutorun m_Autorun;
CDelayController m_ctrDpad;
CDelayController m_ctrIR;
CWebServer* m_pWebServer;
CXBFileZilla* m_pFileZilla;
IPlayer* m_pPlayer;
bool m_bSpinDown;
bool m_bNetworkSpinDown;
DWORD m_dwSpinDownTime;
DWORD m_dwIdleTime;
bool m_bInactive; // CB: SCREENSAVER PATCH
bool m_bScreenSave; // CB: SCREENSAVER PATCH
DWORD m_dwSaverTick; // CB: SCREENSAVER PATCH
DWORD m_dwSkinTime;
protected:
void UpdateLCD();
void FatalErrorHandler(bool InitD3D, bool MapDrives, bool InitNetwork);
bool m_bXboxMediacenterLoaded,m_bSettingsLoaded;
CIMDBMovie m_tagCurrentMovie;
CMusicInfoTag m_tagCurrentSong;
int m_iPlaySpeed;
bool m_bOverlayEnabled;
CStdString m_strCurrentPlayer;
bool m_bAllSettingsLoaded;
CStdString m_strCurrentFile;
D3DGAMMARAMP m_OldRamp; // CB: SCREENSAVER PATCH
};
extern CApplication g_application;
extern CStdString g_LoadErrorStr;

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks