• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

FLVなど sext styp のついた配信のリレーができない問題を修正するパッチ


Commit MetaInfo

Revision740abc7706761ab0ea92a2954c0f4adddb245151 (tree)
Time2010-10-23 00:45:34
Authoreru <eru01@user...>
Commitereru

Log Message

Jumplistへの対応(の下準備)

Change Summary

Incremental Difference

--- a/PeerCast.root/PeerCast/ui/win32/simple/Simple.cpp
+++ b/PeerCast.root/PeerCast/ui/win32/simple/Simple.cpp
@@ -82,6 +82,8 @@ ThreadInfo trafficDlgThread;
8282 HWND trafficDlg = NULL;
8383 FileStream fs;
8484
85+bool jumpListEnabled = false; // jumplist flag (only for win7 or later)
86+
8587 // プロトタイプ宣言
8688 void createGUI(HWND);
8789 LRESULT CALLBACK TrafficDlgProc(HWND, UINT, WPARAM, LPARAM);
@@ -283,14 +285,27 @@ int WinMainDummy(HINSTANCE hInstance,
283285 WIN32_FIND_DATA fd; //JP-EX
284286 HANDLE hFind; //JP-EX
285287
286- OSVERSIONINFO osInfo; //JP-EX
287- osInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); //JP-EX
288- GetVersionEx(&osInfo);
288+ OSVERSIONINFOEX osInfo; //JP-EX
289+ osInfo.dwOSVersionInfoSize = sizeof(osInfo); //JP-EX
290+ GetVersionEx(reinterpret_cast<LPOSVERSIONINFO>(&osInfo));
289291 if (osInfo.dwPlatformId == VER_PLATFORM_WIN32_NT)
290292 winDistinctionNT = true;
291293 else
292294 winDistinctionNT = false;
293295
296+ // for Windows7 or later
297+ if ((osInfo.wProductType == VER_NT_WORKSTATION
298+ && osInfo.dwMajorVersion == 6
299+ && osInfo.dwMinorVersion == 1)
300+ ||
301+ (osInfo.dwMajorVersion == 6
302+ && osInfo.dwMinorVersion > 1)
303+ ||
304+ osInfo.dwMajorVersion > 6)
305+ {
306+ jumpListEnabled = true;
307+ }
308+
294309 // off by default now
295310 showGUI = false;
296311
--- a/PeerCast.root/PeerCast/ui/win32/simple/gui.cpp
+++ b/PeerCast.root/PeerCast/ui/win32/simple/gui.cpp
@@ -56,6 +56,8 @@ bool shownChannels=false;
5656 WINDOWPLACEMENT winPlace;
5757 bool guiFlg = false;
5858
59+extern bool jumpListEnabled;
60+
5961 using namespace Gdiplus;
6062
6163 #include <comdef.h>
@@ -1534,6 +1536,11 @@ void WmCreateProc(HWND hwnd){
15341536 img_broad_ok = ::new Image(bstr);
15351537 bstr = L"ST_BROAD_FULL.bmp";
15361538 img_broad_full = ::new Image(bstr);
1539+
1540+ // jumplist
1541+ if (jumpListEnabled)
1542+ {
1543+ }
15371544 }
15381545
15391546 void WmPaintProc(HWND hwnd){
--- a/c:/Git/PeerCast.root/PeerCast/ui/win32/simple/Simple.cpp
+++ b/c:/Git/PeerCast.root/PeerCast/ui/win32/simple/Simple.cpp
@@ -82,6 +82,8 @@ ThreadInfo trafficDlgThread;
8282 HWND trafficDlg = NULL;
8383 FileStream fs;
8484
85+bool jumpListEnabled = false; // jumplist flag (only for win7 or later)
86+
8587 // プロトタイプ宣言
8688 void createGUI(HWND);
8789 LRESULT CALLBACK TrafficDlgProc(HWND, UINT, WPARAM, LPARAM);
@@ -283,14 +285,27 @@ int WinMainDummy(HINSTANCE hInstance,
283285 WIN32_FIND_DATA fd; //JP-EX
284286 HANDLE hFind; //JP-EX
285287
286- OSVERSIONINFO osInfo; //JP-EX
287- osInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); //JP-EX
288- GetVersionEx(&osInfo);
288+ OSVERSIONINFOEX osInfo; //JP-EX
289+ osInfo.dwOSVersionInfoSize = sizeof(osInfo); //JP-EX
290+ GetVersionEx(reinterpret_cast<LPOSVERSIONINFO>(&osInfo));
289291 if (osInfo.dwPlatformId == VER_PLATFORM_WIN32_NT)
290292 winDistinctionNT = true;
291293 else
292294 winDistinctionNT = false;
293295
296+ // for Windows7 or later
297+ if ((osInfo.wProductType == VER_NT_WORKSTATION
298+ && osInfo.dwMajorVersion == 6
299+ && osInfo.dwMinorVersion == 1)
300+ ||
301+ (osInfo.dwMajorVersion == 6
302+ && osInfo.dwMinorVersion > 1)
303+ ||
304+ osInfo.dwMajorVersion > 6)
305+ {
306+ jumpListEnabled = true;
307+ }
308+
294309 // off by default now
295310 showGUI = false;
296311
--- a/c:/Git/PeerCast.root/PeerCast/ui/win32/simple/gui.cpp
+++ b/c:/Git/PeerCast.root/PeerCast/ui/win32/simple/gui.cpp
@@ -56,6 +56,8 @@ bool shownChannels=false;
5656 WINDOWPLACEMENT winPlace;
5757 bool guiFlg = false;
5858
59+extern bool jumpListEnabled;
60+
5961 using namespace Gdiplus;
6062
6163 #include <comdef.h>
@@ -1534,6 +1536,11 @@ void WmCreateProc(HWND hwnd){
15341536 img_broad_ok = ::new Image(bstr);
15351537 bstr = L"ST_BROAD_FULL.bmp";
15361538 img_broad_full = ::new Image(bstr);
1539+
1540+ // jumplist
1541+ if (jumpListEnabled)
1542+ {
1543+ }
15371544 }
15381545
15391546 void WmPaintProc(HWND hwnd){