#include <appwidget.hh>
Inheritance diagram for otk::AppWidget:
Public Methods | |
AppWidget (Application *app, Direction direction=Horizontal, Cursor cursor=0, int bevel_width=1) | |
virtual | ~AppWidget () |
virtual void | setStyle (RenderStyle *style) |
virtual void | show (void) |
virtual void | hide (void) |
virtual void | clientMessageHandler (const XClientMessageEvent &e) |
Called when a client calls XSendEvent. | |
Private Attributes | |
Application * | _application |
|
Definition at line 17 of file appwidget.cc. References setStyle(), and otk::Widget::window().
00019 : Widget(app, app->getStyle(), direction, cursor, bevel_width), 00020 _application(app) 00021 { 00022 assert(app); 00023 00024 // set WM Protocols on the window 00025 Atom protocols[2]; 00026 protocols[0] = Property::atoms.wm_protocols; 00027 protocols[1] = Property::atoms.wm_delete_window; 00028 XSetWMProtocols(**display, window(), protocols, 2); 00029 00030 setStyle(_style); 00031 } |
|
Definition at line 33 of file appwidget.cc.
00034 { 00035 } |
|
Called when a client calls XSendEvent. Some types of client messages are filtered out and sent to more specific event handler functions. Reimplemented from otk::EventHandler. Definition at line 58 of file appwidget.cc. References hide().
00059 { 00060 EventHandler::clientMessageHandler(e); 00061 if (e.message_type == Property::atoms.wm_protocols && 00062 static_cast<Atom>(e.data.l[0]) == Property::atoms.wm_delete_window) 00063 hide(); 00064 } |
|
Definition at line 51 of file appwidget.cc. References _application, and otk::Application::_appwidget_count. Referenced by clientMessageHandler().
00052 { 00053 Widget::hide(); 00054 00055 _application->_appwidget_count--; 00056 } |
|
Reimplemented from otk::Widget. Definition at line 37 of file appwidget.cc. References otk::Widget::setTexture(), and otk::RenderStyle::titlebarUnfocusBackground(). Referenced by AppWidget().
00038 { 00039 Widget::setStyle(style); 00040 00041 setTexture(style->titlebarUnfocusBackground()); 00042 } |
|
Definition at line 44 of file appwidget.cc. References _application, and otk::Application::_appwidget_count. Referenced by main().
00045 { 00046 Widget::show(true); 00047 00048 _application->_appwidget_count++; 00049 } |
|
Definition at line 27 of file appwidget.hh. |