desktop switching: allow applications to be visible only on one desktop

svn path=/trunk/; revision=8446
This commit is contained in:
Martin Fuchs 2004-02-28 15:14:38 +00:00
parent 44cb45b570
commit a5248aa7bc
2 changed files with 18 additions and 23 deletions

View file

@ -182,10 +182,18 @@ void Desktops::SwitchToDesktop(int idx)
WindowSet& windows = old_desktop._windows;
windows.clear();
// collect window handles of all other desktops
WindowSet other_wnds;
for(const_iterator it1=begin(); it1!=end(); ++it1)
for(WindowSet::const_iterator it2=it1->_windows.begin(); it2!=it1->_windows.end(); ++it2)
other_wnds.insert(*it2);
EnumWindows(SwitchDesktopEnumFct, (LPARAM)&windows);
old_desktop._hwndForeground = (HWND)SendMessage(g_Globals._hwndDesktopBar, PM_GET_LAST_ACTIVE, 0, 0);
// hide all windows we found
// hide all windows of the previous desktop
for(WindowSet::iterator it=windows.begin(); it!=windows.end(); ++it)
ShowWindowAsync(*it, SW_HIDE);
@ -196,6 +204,11 @@ void Desktops::SwitchToDesktop(int idx)
if (desktop._hwndForeground)
SetForegroundWindow(desktop._hwndForeground);
// remove the window handles of the other desktops from what we found on the previous desktop
for(WindowSet::const_iterator it=other_wnds.begin(); it!=other_wnds.end(); ++it)
windows.erase(*it);
// We don't need to store the window handles of what's now visible the now current desktop.
desktop._windows.clear();
_current_desktop = idx;

View file

@ -21,8 +21,11 @@
- implement blink effect in task bar for SetForegoundWindow() requests
- implement more than one column or scrolling in start menus for very crowded start menus
- Execute selected programs with additional command line options ("Run" dialog with pre-filled edit field)
- switch background images with desktop switcher
- Desktop Manager: Desktop Names; Speicherung der Verteilung von Applikations-Fenstern auf die verschiedenen Desktops -> config file
- autostart doesn't work on NT4 ?
- hide desktop bar when showing full screen applications
- new start menu entry "Filemanager" close to "Explore" -> display C: and D: drive in MDI window
- Startmenu: You can't close the start menu with pressing Win-key You can open the start menu
with pressing Win-key, but can't close with another hit of Win-key.
@ -32,24 +35,3 @@
Yes, ROS explorer doesn't read many settings from the registry currently,
as it doesn't have a way to configure them. (missing configuration dialogs)
- Vollbildfenster suchen -> Taskleiste ausblenden
- Desktop-Manager: Speicherung der Verteilung von Applikations-Fenstern auf die verschiedenen Desktops; Desktop-Namen
- neuer Startmenü-Eintrag: "Filemanager" neben "Explore" -> Anzeige von C: und D:
> When minimizing window such as Sleipnir; a popular
> IE-based tab browser in Japan:
> http://www20.pos.to/~sleipnir/software/sleipnir/index.html
> the window'll not stored into the notification area but just minimized; instead of the setting.
> This might be a problem of application which doesn't handle the event, but it works under MS-explorer.
> I tested on 1.42JA, but I also tested and it reproduced on 1.41EN.
> The setting are: Tools->Sleipnir Options->System Tray->turn both settings on
> When you click the minimize button on the top-right of the window, it
> minimizes successfully into SysTray, but on the other hand, when you minimize the
> window by clicking the taskbutton, it minimizes but doesn't go into SysTray.
> mIRC doesn't expect to be on two desktops at the same time.
> There may be a internal variables, which say: "I am minimized or not." and
> "I am visible or not." So I will have to adjust desktop switching in a
> way, that applications are either visible or not - but not mixed between two
> different desktops.