Blitz+ users a new way of opening windows...
BlitzPlus Forums/BlitzPlus Programming/Blitz+ users a new way of opening windows...
| ||
'k Any program that used Findwindow to get the HWND of the blitz basic window doesn't work anymore, this includes both mine and peters OpenGL extensions since we used that method... the reason is that it doesn't seem to be a "GX_WIN32_CLASS" anymore for the window class So is there anyway around this, or do I have to find the window another way... Also how do you get the HWND of Gadgets? since unless I've gone blind there is no reference to this in the docs. later. |
| ||
'k if you use a dll call to find window you can't find it. but if you wrote a wrapper to get the window. you put NULL in as the class ie findwindow(NULL,title); where title is a array of chars |
| ||
Theres a new command in blitz+ to help now...pWindow=createwindow(...) hwnd=QueryObject(pwindow,1) Online doc located here |
| ||
I guess this is why none of my popup menus appear anymore, If I replace FindWindow("GX_WIN32_CLASS", "WindowNmame" ) with QueryObject( window, 1 ) I get a valid return from QueryObject but not from FindWindow or Find Menu, SubMenu. Why are these types not supported under the new QueryObject command ??? |
| ||
I will be updateing my code shortly. For now simple use "BLITZMAX_WINDOW_CLASS" instead of "GX_WIN32_CLASS" |
| ||
Listen to Shagwana. It's far easier to just say: win = CreateWindow(...) hwnd = QueryObject(win,1) Oh no, for some reason the GetMenu() API call doesn't like hwnd's collected from QueryObject() and you can't use QueryObject() on a menu item.. So you have to use "BLITZMAX_WINDOW_CLASS" instead, as Peter said. |
| ||
you must specify "Blitz Runtime Class" as the class of the Window. |
| ||
"Blitz Runtime Class" is for B3D "GX_WIN32_CLASS" is for B+ version 1.1 "BLITZMAX_WINDOW_CLASS" is for B+ version 1.34 |