[Home] [Downloads] [Search] [Help/forum]

Gammon Software Solutions forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Suggestions
. . -> [Subject]  Get Plugin (its id) that miniwindow was created from

Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

Get Plugin (its id) that miniwindow was created from

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page


Posted by Bast   (76 posts)  [Biography] bio
Date Wed 08 Feb 2012 03:31 PM (UTC)  quote  ]

Amended on Wed 08 Feb 2012 03:33 PM (UTC) by Bast

Message
Could we get it added it to WindowInfo please. I am currently working on a plugin that will save window states (position,size,etc) and would like to be able to find which plugin created a window.

Unless there is some other way to get this?

Bast

Bast

Scripts: http://bastmush.googlecode.com
[Go to top] top

Posted by Kevnuke   USA  (83 posts)  [Biography] bio
Date Reply #1 on Wed 08 Feb 2012 06:44 PM (UTC)  quote  ]
Message
I haven't personally made any miniwindows, but from what I've seen experienced plugin writers assign things like that to a variable and then use the variables as arguments to the function they are using, WindowCreate, for example. If the plugin itself saves it's state this shouldn't be needed. If it doesn't, the value of these variables can be saved in client variables and retrieved later by the plugin.

How are you planning to use this information once you get it?

I'm curious because I'm putting everything for my curing system into one plugin.
[Go to top] top

Posted by Nick Gammon   Australia  (18,770 posts)  [Biography] bio   Forum Administrator
Date Reply #2 on Wed 08 Feb 2012 07:25 PM (UTC)  quote  ]
Message
The plugin ID, by convention, is supposed to be part of the miniwindow ID, to avoid clashes with other plugins. However it possibly would not be the first or last part of the name.

I've added selector 23 to WindowInfo for version 4.82 which will have this information.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Bast   (76 posts)  [Biography] bio
Date Reply #3 on Thu 09 Feb 2012 03:22 PM (UTC)  quote  ]
Message

Yes, I will use the plugin id. The plan is to query the plugins for certain functions and if those functions exist, call those functions with the new states. For example, if the plugin is using Nick's movewindow.lua, I will call movewindow.save_state(windowid) and it will save the new coords. There will be similar functionality for plugins that I write.

Bast

Bast

Scripts: http://bastmush.googlecode.com
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


804 views.

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

[Home]

Written by Nick Gammon - 5K

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Internet Contents Rating Association (ICRA) - 2K]    [Web site powered by FutureQuest.Net]