Re: [Cppcms-users] Plugins and templates
Brought to you by:
artyom-beilis
From: Artyom <art...@ya...> - 2010-08-20 07:02:47
|
Hello, Also there is a solution you can do: 1. Compile the skin into the plugin: i.e. create cpp sources for skin and link them into the plugin shared object. 2. When shared object is loaded, it would be automatically loaded to static instance of views pool and unloaded when shared object goes. 3. In the plugin itself you can use views_pool::static_instance().render(...) to render the view. 4. Note: you can't load and unload two plugins simultaneously as it would not be thread safe, 5. When plugin is unloaded, the skin would be automatically unregistered from the static_instance of views_pool. Note: this behavior is undocumented and may be changed in future. You'll get the notice about it. Artyom ----- Original Message ---- > From: Artyom <art...@ya...> > To: cpp...@li... > Sent: Fri, August 20, 2010 9:46:29 AM > Subject: Re: [Cppcms-users] Plugins and templates > > > > > Would it be possible to register a view at runtime? > > > > Not sure. It would required making views loading > and unloading be thread safe and make the interaction > with actual DLL quite complicated. > > However, I do not really like the views_pool implementation so it > is likely to be updated and may be this feature including unloading views > may be implemented > > > You may open feature request in bug tracking system > > Artyom > > > > > > ------------------------------------------------------------------------------ > This SF.net email is sponsored by > > Make an app they can't live without > Enter the BlackBerry Developer Challenge > http://p.sf.net/sfu/RIM-dev2dev > _______________________________________________ > Cppcms-users mailing list > Cpp...@li... > https://lists.sourceforge.net/lists/listinfo/cppcms-users > |