void CCompositor::KeyState(unsigned int KeyboardID, uint32_t KeySym, bool Press, uint32_t Codepoint)
{
_SysDebug("KeyState(%i, 0x%x, %b, 0x%x)", KeyboardID, KeySym, Press, Codepoint);
+ // TODO: Global hotkeys
if( m_focussed_window )
{
m_focussed_window->KeyEvent(KeySym, "", Press);
}
void SendMessage_MouseMove(CClient& client, unsigned int WinID, unsigned int X, unsigned int Y)
{
- _SysDebug("TODO: IPC::SendMessage_MouseButton");
+ _SysDebug("TODO: IPC::SendMessage_MouseMove");
}
void SendMessage_KeyEvent(CClient& client, unsigned int WinID, uint32_t KeySym, bool Pressed, const char *Translated)
{
}
else
{
- AxWin4_FillRect(bgwin, 0, 0, w, h, 0x0000CC);
+ AxWin4_FillRect(bgwin, 0, 0, w, h, 0x8888CC);
}
//AxWin4_DamageRect(bgwin, 0, 0, w, h);
AxWin4_ShowWindow(bgwin, true);
strftime(timestr, 5, "%H%M", localtime(&rawtime));
//AxWin4_DrawControl(gpTaskbar_Window, clock_start_x, TASKBAR_BORDER, TASKBAR_CLOCKSIZE, active_height, AXWIN4_CTL_BOX);
- //unsigned int clock_height = 16; // Hard-code the standard font height
- //unsigned int clock_yofs = (active_height - clock_height)/2;
- //AxWin4_DrawText(gpTaskbar_Window, clock_start_x, TASKBAR_BORDER + clock_yofs, TASKBAR_CLOCKSIZE, clock_height, 0, timestr);
AxWin4_DrawText(gpTaskbar_Window, clock_start_x, TASKBAR_BORDER, TASKBAR_CLOCKSIZE, active_height, 0, timestr);
-
- //AxWin4_DrawText(gpTaskbar_Window, clock_start_x, TASKBAR_BORDER, TASKBAR_CLOCKSIZE, 16, 0, timestr);
}
AxWin4_DamageRect(gpTaskbar_Window, 0, 0, w, h);
extern tAxWin4_Window *AxWin4_CreateWindow(const char *Name);
extern void AxWin4_DestroyWindow(tAxWin4_Window *Window);
+
+// Callbacks
+typedef int tAxWin4_KeyCallback(tAxWin4_Window* Winow, unsigned int Key, const char *Translated);
+extern void AxWin4_SetCallback_Key(tAxWin4_Window* Window, tAxWin4_KeyCallback* cb);
+typedef int tAxWin4_MouseBtnCallback(tAxWin4_Window* Winow, unsigned int Mouse, unsigned int X, unsigned int Y, unsigned int Button, bool IsPress);
+extern void AxWin4_SetCallback_MouseBtn(tAxWin4_Window* Window, tAxWin4_MouseBtnCallback* cb);
+typedef int tAxWin4_MouseMoveCallback(tAxWin4_Window* Winow, unsigned int Mouse, unsigned int X, unsigned int Y);
+
extern void AxWin4_ShowWindow(tAxWin4_Window *Window, bool Shown);
extern void AxWin4_SetWindowFlags(tAxWin4_Window *Window, unsigned int NewFlags);
extern void AxWin4_SetTitle(tAxWin4_Window *Window, const char *Title);