Changeset 8513 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Apr 30, 2008 3:15:49 PM (17 years ago)
- svn:sync-xref-src-repo-rev:
- 30408
- Location:
- trunk/src/VBox/Frontends
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/include/VBoxConsoleWnd.h
r8456 r8513 190 190 void onEnterFullscreen(); 191 191 void onExitFullscreen(); 192 void exitFullscreen(); 192 193 void exitSeamless(); 193 194 -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp
r8477 r8513 1024 1024 void VBoxConsoleWnd::onEnterFullscreen() 1025 1025 { 1026 LogFlowThisFunc(("\n"));1027 1026 disconnect (console, SIGNAL (resizeHintDone()), 0, 0); 1028 1027 /* It isn't guaranteed that the guest os set the video mode that … … 1044 1043 connect (console, SIGNAL (resizeHintDone()), 1045 1044 this, SLOT(exitSeamless())); 1046 LogFlowThisFunc(("return\n")); 1045 else if (mIsFullscreen) 1046 connect (console, SIGNAL (resizeHintDone()), 1047 this, SLOT(exitFullscreen())); 1047 1048 } 1048 1049 … … 1053 1054 void VBoxConsoleWnd::onExitFullscreen() 1054 1055 { 1055 LogFlowThisFunc(("\n"));1056 1056 disconnect (console, SIGNAL (resizeHintDone()), 0, 0); 1057 1057 #ifdef Q_WS_MAC … … 1069 1069 console->setIgnoreMainwndResize (false); 1070 1070 console->normalizeGeometry (true /* adjustPosition */); 1071 LogFlowThisFunc(("returning\n")); 1071 } 1072 1073 /** 1074 * This slot is called if the guest changes resolution while in fullscreen 1075 * mode. 1076 */ 1077 void VBoxConsoleWnd::exitFullscreen() 1078 { 1079 if (mIsFullscreen && vmFullscreenAction->isEnabled()) 1080 vmFullscreenAction->toggle(); 1072 1081 } 1073 1082 … … 1078 1087 void VBoxConsoleWnd::exitSeamless() 1079 1088 { 1080 vmSeamlessAction->setOn (false); 1089 if (mIsSeamless && vmSeamlessAction->isEnabled()) 1090 vmSeamlessAction->toggle(); 1081 1091 } 1082 1092 … … 1946 1956 bool VBoxConsoleWnd::toggleFullscreenMode (bool aOn, bool aSeamless) 1947 1957 { 1948 LogFlowThisFunc(("aOn=%s, aSeamless=%s\n", aOn ? "true" : "false", aSeamless ? "true" : "false"));1949 1958 disconnect (console, SIGNAL (resizeHintDone()), 0, 0); 1950 1959 if (aSeamless) … … 2210 2219 hide(); 2211 2220 #endif 2212 LogFlowThisFunc(("true\n"));2213 2221 return true; 2214 2222 } … … 3239 3247 /* If seamless mode should be enabled then check if it is enabled 3240 3248 * currently and re-enable it if open-view procedure is finished */ 3241 if (vmSeamlessAction->isOn()) 3242 { 3243 if ( mIsOpenViewFinished 3244 && aSeamlessSupported 3245 && aGraphicsSupported) 3246 { 3247 if (!mIsSeamless) 3248 toggleFullscreenMode (true /* aOn */, true /* aSeamless */); 3249 } 3250 else 3251 { 3252 if (mIsSeamless) 3253 toggleFullscreenMode (false /* aOn */, true /* aSeamless */); 3254 } 3255 } 3249 if ( vmSeamlessAction->isOn() 3250 && mIsOpenViewFinished 3251 && aSeamlessSupported 3252 && aGraphicsSupported) 3253 toggleFullscreenMode (true, true); 3256 3254 /* Disable auto-resizing if advanced graphics are not available */ 3257 3255 console->setAutoresizeGuest ( mIsGraphicsSupported -
trunk/src/VBox/Frontends/VirtualBox4/include/VBoxConsoleWnd.h
r8456 r8513 190 190 void onEnterFullscreen(); 191 191 void onExitFullscreen(); 192 void exitFullscreen(); 192 193 void exitSeamless(); 193 194 -
trunk/src/VBox/Frontends/VirtualBox4/src/VBoxConsoleWnd.cpp
r8477 r8513 1035 1035 void VBoxConsoleWnd::onEnterFullscreen() 1036 1036 { 1037 LogFlowFuncEnter();1038 1037 disconnect (console, SIGNAL (resizeHintDone()), 0, 0); 1039 1038 /* It isn't guaranteed that the guest os set the video mode that … … 1055 1054 connect (console, SIGNAL (resizeHintDone()), 1056 1055 this, SLOT(exitSeamless())); 1057 LogFlowFuncLeave(); 1056 else if (mIsFullscreen) 1057 connect (console, SIGNAL (resizeHintDone()), 1058 this, SLOT(exitFullscreen())); 1058 1059 } 1059 1060 … … 1064 1065 void VBoxConsoleWnd::onExitFullscreen() 1065 1066 { 1066 LogFlowFuncEnter();1067 1067 disconnect (console, SIGNAL (resizeHintDone()), 0, 0); 1068 1068 #ifdef Q_WS_MAC … … 1080 1080 console->setIgnoreMainwndResize (false); 1081 1081 console->normalizeGeometry (true /* adjustPosition */); 1082 LogFlowFuncLeave(); 1082 } 1083 1084 /** 1085 * This slot is called if the guest changes resolution while in fullscreen 1086 * mode. 1087 */ 1088 void VBoxConsoleWnd::exitFullscreen() 1089 { 1090 if (mIsFullscreen && vmFullscreenAction->isEnabled()) 1091 vmFullscreenAction->toggle(); 1083 1092 } 1084 1093 … … 1089 1098 void VBoxConsoleWnd::exitSeamless() 1090 1099 { 1091 vmSeamlessAction->setChecked (false); 1100 if (mIsSeamless && vmSeamlessAction->isEnabled()) 1101 vmSeamlessAction->toggle(); 1092 1102 } 1093 1103 … … 1969 1979 bool VBoxConsoleWnd::toggleFullscreenMode (bool aOn, bool aSeamless) 1970 1980 { 1971 LogFlowThisFunc(("aOn=%s, aSeamless=%s\n", aOn ? "true" : "false", aSeamless ? "true" : "false"));1972 1981 disconnect (console, SIGNAL (resizeHintDone()), 0, 0); 1973 1982 if (aSeamless) … … 2240 2249 hide(); 2241 2250 #endif 2242 LogFlowThisFunc(("true\n"));2243 2251 return true; 2244 2252 } … … 3280 3288 /* If seamless mode should be enabled then check if it is enabled 3281 3289 * currently and re-enable it if open-view procedure is finished */ 3282 if (vmSeamlessAction->isOn()) 3283 { 3284 if ( mIsOpenViewFinished 3285 && aSeamlessSupported 3286 && aGraphicsSupported) 3287 { 3288 if (!mIsSeamless) 3289 toggleFullscreenMode (true /* aOn */, true /* aSeamless */); 3290 } 3291 else 3292 { 3293 if (mIsSeamless) 3294 toggleFullscreenMode (false /* aOn */, true /* aSeamless */); 3295 } 3296 } 3290 if ( vmSeamlessAction->isChecked() 3291 && mIsOpenViewFinished 3292 && aSeamlessSupported 3293 && aGraphicsSupported) 3294 toggleFullscreenMode (true, true); 3297 3295 /* Disable auto-resizing if advanced graphics are not available */ 3298 3296 console->setAutoresizeGuest ( mIsGraphicsSupported
Note:
See TracChangeset
for help on using the changeset viewer.