View Single Post
  #24  
Unread 03-08-2005, 03:03 AM
Talyns's Avatar
Talyns Talyns is offline
A Griffon
This person is a EQ2Map developer.
Interface Author - Click to view interfaces
 
Join Date: Jul 2004
Server: Everfrost
Posts: 604
Default

I was thinking of a way to add some kinde of OnEvent code to the above plugin system..

Could add 4 buttons in plugins.xml OnHide OnShow OnMinimize OnRestore..
The OnActivate for them would be..

Parent.Parent.TM_Plugin1.OnEvent.Activated=true
Parent.Parent.TM_Plugin2.OnEvent.Activated=true
Parent.Parent.TM_Plugin3.OnEvent.Activated=true
Parent.Parent.TM_Plugin4.OnEvent.Activated=true
Parent.Parent.TM_Plugin5.OnEvent.Activated=true
Activated=false

Don't have to add anything to any of the blank plugins..


If a modder wanted something to happen when the window minimizes: he/she would add a button to the plugin page called OnMinimize.. Then set the OnActivate script to get something to useful and ending it with Activated=false

For Instance:
I want to add a minimize button to the minimap that presses the mainwindows minimize..
Right now that won't work because my windows cover the titlebar.. But if I had the on events I could save the visible state of my title bar on minimize..

Then in OnRestore I use that visible state to press(or not press) my DockButton to change the window back to its minimap state

I will sleep on it aand work on adding it tomorrow night..

Forgot to mention the OnHide of the main map window would call the OnHide button.. The OnShow would be called in the final version OnShow.. Restore and Minimize in the Onactivate events of those buttons in the title bar
__________________
Talyns

Last edited by Talyns : 03-08-2005 at 03:07 AM.
Reply With Quote