mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Fix some window title issues, etc.
This commit is contained in:
parent
e5c6cea6f1
commit
87e51a5c04
6 changed files with 10 additions and 19 deletions
|
@ -181,6 +181,7 @@ void CPU_Init() {
|
|||
return;
|
||||
}
|
||||
|
||||
|
||||
if (coreParameter.updateRecent) {
|
||||
g_Config.AddRecent(filename);
|
||||
}
|
||||
|
@ -290,6 +291,7 @@ void PSP_Shutdown() {
|
|||
CPU_Shutdown();
|
||||
}
|
||||
GPU_Shutdown();
|
||||
host->SetWindowTitle(0);
|
||||
}
|
||||
|
||||
void PSP_RunLoopUntil(u64 globalticks) {
|
||||
|
|
|
@ -192,6 +192,9 @@ namespace DSound
|
|||
|
||||
void DSound_StopSound()
|
||||
{
|
||||
if (!dsBuffer)
|
||||
return;
|
||||
|
||||
if (threadData == 0)
|
||||
threadData = 1;
|
||||
|
||||
|
@ -227,11 +230,8 @@ namespace DSound
|
|||
return playCursor;
|
||||
}
|
||||
|
||||
|
||||
|
||||
float DSound_GetTimer()
|
||||
{
|
||||
return (float)DSound_GetCurSample()*(1.0f/(4.0f*44100.0f));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -96,7 +96,9 @@ void WindowsHost::ShutdownGL()
|
|||
|
||||
void WindowsHost::SetWindowTitle(const char *message)
|
||||
{
|
||||
std::string title = std::string("PPSSPP ") + PPSSPP_GIT_VERSION + " - " + message;
|
||||
std::string title = std::string("PPSSPP ") + PPSSPP_GIT_VERSION;
|
||||
if (message)
|
||||
title = title + " - " + message;
|
||||
|
||||
int size = MultiByteToWideChar(CP_UTF8, 0, title.c_str(), (int) title.size(), NULL, 0);
|
||||
if (size > 0)
|
||||
|
|
|
@ -333,7 +333,6 @@ namespace MainWindow
|
|||
SetTimer(hwndMain, TIMER_CURSORUPDATE, CURSORUPDATE_INTERVAL_MS, 0);
|
||||
|
||||
Update();
|
||||
SetPlaying(0);
|
||||
|
||||
if(g_Config.bFullScreenOnLaunch)
|
||||
_ViewFullScreen(hwndMain);
|
||||
|
@ -694,7 +693,6 @@ namespace MainWindow
|
|||
Core_EnableStepping(false);
|
||||
}
|
||||
NativeMessageReceived("stop", "");
|
||||
SetPlaying(0);
|
||||
Update();
|
||||
break;
|
||||
|
||||
|
@ -1156,8 +1154,7 @@ namespace MainWindow
|
|||
// Ugly, need to wait for the stop message to process in the EmuThread.
|
||||
Sleep(20);
|
||||
|
||||
MainWindow::SetPlaying(filename);
|
||||
MainWindow::Update();
|
||||
Update();
|
||||
|
||||
NativeMessageReceived("boot", filename);
|
||||
}
|
||||
|
@ -1497,16 +1494,6 @@ namespace MainWindow
|
|||
UpdateScreenScale();
|
||||
}
|
||||
|
||||
void SetPlaying(const char *text) {
|
||||
char temp[256];
|
||||
if (text == 0)
|
||||
snprintf(temp, 256, "PPSSPP %s", PPSSPP_GIT_VERSION);
|
||||
else
|
||||
snprintf(temp, 256, "%s - PPSSPP %s", text, PPSSPP_GIT_VERSION);
|
||||
temp[255] = '\0';
|
||||
SetWindowText(hwndMain, temp);
|
||||
}
|
||||
|
||||
void SaveStateActionFinished(bool result, void *userdata) {
|
||||
PostMessage(hwndMain, WM_USER_SAVESTATE_FINISH, 0, 0);
|
||||
}
|
||||
|
|
|
@ -50,7 +50,6 @@ namespace MainWindow
|
|||
HWND GetHWND();
|
||||
HINSTANCE GetHInstance();
|
||||
HWND GetDisplayHWND();
|
||||
void SetPlaying(const char*text);
|
||||
void BrowseAndBoot(std::string defaultPath, bool browseDirectory = false);
|
||||
void SaveStateActionFinished(bool result, void *userdata);
|
||||
void _ViewFullScreen(HWND hWnd);
|
||||
|
|
|
@ -123,6 +123,7 @@ int WINAPI WinMain(HINSTANCE _hInstance, HINSTANCE hPrevInstance, LPSTR szCmdLin
|
|||
DialogManager::AddDlg(vfpudlg = new CVFPUDlg(_hInstance, hwndMain, currentDebugMIPS));
|
||||
|
||||
host = new WindowsHost(hwndMain, hwndDisplay);
|
||||
host->SetWindowTitle(0);
|
||||
|
||||
// Emu thread is always running!
|
||||
EmuThread_Start();
|
||||
|
|
Loading…
Add table
Reference in a new issue