# http://ruby-doc.org/docs/ProgrammingRuby/html/lib_windows.html#Win32API.new require 'Win32API' WS_CAPTION = 0x00C00000 WS_EX_TOOLWINDOW = 0x00000080 GWL_STYLE = -16 GWL_EXSTYLE = -20 # SetWindowPos() flags SWP_NOSIZE = 0x0001 SWP_NOMOVE = 0x0002 SWP_DRAWFRAME = 0x0020 SWP_FRAMECHANGED = 0x0020 SWP_NOREPOSITION = 0x0200 # Windows Functions #FindWindow = Win32API.new("user32.dll" , "FindWindow" , 'PP' , 'L') #FindWindowEx = Win32API.new("user32.dll", "FindWindowEx" , 'LLPP', 'L') SetWindowPos = Win32API.new("user32.dll" , "SetWindowPos" , 'LLIIIII', 'I') SetWindowLong = Win32API.new("user32.dll" , "SetWindowLong", 'LIL', 'L') GetWindowLong = Win32API.new("user32.dll" , "GetWindowLong", 'LI' , 'L') GetActiveWindow = Win32API.new("user32.dll", "GetActiveWindow", '', 'L') #GetForegroundWindow = Win32API.new("user32.dll", "GetForegroundWindow", '', 'L') GetWindowText = Win32API.new("user32.dll", "GetWindowText", 'LPI', 'I') GetWindowTextLength = Win32API.new("user32.dll", "GetWindowTextLength", 'L', 'I') def create_toolbar_window window = UI::WebDialog.new('My Test Window', false) window.set_html('
My very own window