Public Types | Public Member Functions | Protected Attributes

TaskbarSettingsDlg Struct Reference

"Taskbar Settings" Property Sheet Dialog More...

#include <settings.h>

Inheritance diagram for TaskbarSettingsDlg:
Inheritance graph
[legend]
Collaboration diagram for TaskbarSettingsDlg:
Collaboration graph
[legend]

List of all members.

Public Types

typedef PropSheetPageDlg super

Public Member Functions

 TaskbarSettingsDlg (HWND hwnd)
virtual int Command (int id, int code)
virtual int Notify (int id, NMHDR *pnmh)

Protected Attributes

XMLDoc _cfg_org

Detailed Description

"Taskbar Settings" Property Sheet Dialog

Definition at line 65 of file settings.h.


Member Typedef Documentation

Reimplemented from PropSheetPageDlg.

Definition at line 67 of file settings.h.


Constructor & Destructor Documentation

TaskbarSettingsDlg::TaskbarSettingsDlg ( HWND  hwnd )

Definition at line 158 of file settings.cpp.

References g_Globals, ExplorerGlobals::get_cfg(), ID_HIDE_INACTIVE_ICONS, and ID_SHOW_CLOCK.

 :  super(hwnd),
    _cfg_org(g_Globals._cfg)
{
    XMLPos options = g_Globals.get_cfg("desktopbar/options");

    CheckDlgButton(hwnd, ID_SHOW_CLOCK, XMLBool(options, "show-clock", true)? BST_CHECKED: BST_UNCHECKED);
    CheckDlgButton(hwnd, ID_HIDE_INACTIVE_ICONS, XMLBool(options, "hide-inactive", true)? BST_CHECKED: BST_UNCHECKED);
}

Here is the call graph for this function:


Member Function Documentation

int TaskbarSettingsDlg::Command ( int  id,
int  code 
) [virtual]

Reimplemented from PropSheetPageDlg.

Definition at line 187 of file settings.cpp.

References WindowHandle::_hwnd, ExplorerGlobals::_hwndDesktopBar, Dialog::DoModal(), g_Globals, ExplorerGlobals::get_cfg(), ID_CONFIG_NOTIFYAREA, ID_HIDE_INACTIVE_ICONS, ID_SHOW_CLOCK, IDD_NOTIFYAREA, PM_REFRESH_CONFIG, XMLStorage::XMLBoolRef::toggle(), and WINDOW_CREATOR.

{
    switch(id) {
      case ID_CONFIG_NOTIFYAREA:
        Dialog::DoModal(IDD_NOTIFYAREA, WINDOW_CREATOR(TrayNotifyDlg), _hwnd);
        break;

      case ID_SHOW_CLOCK: {
        XMLBoolRef boolRef1(XMLPos(g_Globals.get_cfg("desktopbar/options")), "show-clock", true);
        boolRef1.toggle();
        SendMessage(g_Globals._hwndDesktopBar, PM_REFRESH_CONFIG, 0, 0);
        PropSheet_Changed(GetParent(_hwnd), _hwnd);
        break;}

      case ID_HIDE_INACTIVE_ICONS: {
        XMLBoolRef boolRef2(XMLPos(g_Globals.get_cfg("notify-icons/options")), "hide-inactive", true);
        boolRef2.toggle();
        SendMessage(g_Globals._hwndDesktopBar, PM_REFRESH_CONFIG, 0, 0);
        PropSheet_Changed(GetParent(_hwnd), _hwnd);
        break;}

      default:
        return 1;
    }

    return 0;
}

Here is the call graph for this function:

int TaskbarSettingsDlg::Notify ( int  id,
NMHDR *  pnmh 
) [virtual]

Reimplemented from Window.

Definition at line 168 of file settings.cpp.

References ExplorerGlobals::_cfg, _cfg_org, ExplorerGlobals::_hwndDesktopBar, g_Globals, Window::Notify(), and PM_REFRESH_CONFIG.

{
    switch(pnmh->code) {
      case PSN_APPLY:
        _cfg_org = g_Globals._cfg;
        break;

      case PSN_RESET:
        g_Globals._cfg = _cfg_org;
        SendMessage(g_Globals._hwndDesktopBar, PM_REFRESH_CONFIG, 0, 0);
        break;

      default:
        return super::Notify(id, pnmh);
    }

    return 0;
}

Here is the call graph for this function:


Member Data Documentation

XMLDoc TaskbarSettingsDlg::_cfg_org [protected]

Definition at line 75 of file settings.h.

Referenced by Notify().


The documentation for this struct was generated from the following files:

ROS Explorer Source Code Documentation
generated on 02.01.2013 by doxygen

ROS Explorer Homepage