it'd be nice to have a "#PB_output_type" to denote whether we are compiling a DLL or EXE. i have some sources with procedures that use global hooks, which must of course be in a shared DLL. they are part of a larger project that id like to make available as a .pbi, a DLL, and a PB tailbite LIB.
i hate maintaining three separate sources, as i have to continually copy and paste updated procedures between each. it would be nice to have this:
Code: Select all
compilerif Outputtype()=#pb_shared_DLL
procedure global_hook_procedure(parameter, hinstance)
do something
endprocedure
procedure1(value.l)
set the hook in the DLL
endprocedure
compilerendif
then i can always maintain a windowed program even inside a DLL source for testing purposes of the procedures, instead of having to compile the DLL, switch back to the exe source, fix that ect. essentially it would make things easier and mgiht add some advantages people hadnt thought of.
Code: Select all
compilerif Outputtype()=#pb_exe
window=openwindow(..........
repeat
until event loop = done
compilerendif