home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Language specific support
MediaPortal Forums Francais
MediaPortal 1 - Développement
Les plugins
Squelette de plugin
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="WhyMe" data-source="post: 482903" data-attributes="member: 80405"><p>Hello la compagnie,</p><p>le plugin AutoStart que j'ai tjs utilisé ne fonctionne plus avec la 1.1a ( çà devait bien arriver un jour ).</p><p>Je me dis : je vais le recompiler et zou çà va repartir.</p><p>Oui mais non : pas mal de chose on changé avec la 1.1a et impossible de recompiler le code.</p><p>Alors je me dis : après tout je veux juste démarrer la télé à chaque démarrage de MP, spa compliqué, je vais faire un plugin tout neuf.</p><p></p><p>J'ai donc un bout de code super compliqué qui marche pas <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite8" alt=":D" title="Big Grin :D" loading="lazy" data-shortname=":D" /></p><p></p><p>La DLL est bien chargée, mais je ne passe pas ds le Start</p><p></p><p>C'est un pb que j'avais déjà rencontré avec une version précédente de MP et un bout de code que j'avais fais pour tout autre chose, j'avais finis par débloquer le pb, mais je ne sais plus comment <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite3" alt=":(" title="Frown :(" loading="lazy" data-shortname=":(" /></p><p></p><p>Une idée ?</p><p></p><p>[CODE]2009-07-07 22:03:33.046875 [Info.][MPMain]: PlugInManager.Load()</p><p>[B]2009-07-07 22:03:33.046875 [Info.][MPMain]: Load plugins from : C:\Program Files\Team MediaPortal\MediaPortal\Plugins\process\MyPlugin.dll</p><p>2009-07-07 22:03:33.062500 [Info.][MPMain]: File Version : 1.0.0.0</p><p>[/B]2009-07-07 22:03:33.062500 [Info.][MPMain]: Load plugins from : C:\Program Files\Team MediaPortal\MediaPortal\Plugins\process\ProcessPlugins.dll</p><p>2009-07-07 22:03:33.078125 [Info.][MPMain]: File Version : 1.0.3.23090</p><p>2009-07-07 22:03:33.078125 [Info.][MPMain]: PlugInManager.Start()</p><p>2009-07-07 22:03:33.890625 [Debug][MPMain]: d3dapp: ShowLastActiveModule active : False</p><p>2009-07-07 22:03:33.921875 [Info.][MPMain]: opening video database</p><p>2009-07-07 22:03:33.921875 [Info.][MPMain]: video database opened</p><p>2009-07-07 22:03:34.031250 [Info.][MPMain]: xml:C:\Documents and Settings\All Users\Application Data\Team MediaPortal\MediaPortal\Skin\Blue3wide\topbar.xml image id:1 width:0 height:0 gfx:empty.png</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:0 debug</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:1 font10</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:2 font11</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:3 font12</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:4 font13</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:5 font14</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:6 font15</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:7 font16</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:8 font17</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:9 font18</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:10 dingbats</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:11 font32</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:12 font48</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:13 font60</p><p>2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:14 fontSVT</p><p>2009-07-07 22:03:44.421875 [Info.][MPMain]: TexturePacker: disposing texture:1999</p><p>2009-07-07 22:03:44.421875 [Info.][MPMain]: TexturePacker: disposing texture:1998</p><p>2009-07-07 22:03:44.437500 [Info.][MPMain]: TexturePacker: disposing texture:1996</p><p>2009-07-07 22:03:44.453125 [Debug][MPMain]: TVHome: HeartBeat Transmitter stopped.</p><p>2009-07-07 22:03:44.468750 [Debug][MPMain]: Main: SaveLastActiveModule - enabled False</p><p>2009-07-07 22:03:44.468750 [Info.][MPMain]: Main: Exiting</p><p>2009-07-07 22:03:44.468750 [Info.][MPMain]: PlugInManager.Stop()</p><p>[/CODE]</p><p>[CODE]using System ;</p><p>using System.Text ;</p><p>using System.Collections ;</p><p></p><p>using MediaPortal.GUI.Library ;</p><p></p><p>namespace ProcessPlugins.MyPlugin</p><p>{</p><p> /// <summary></p><p> /// </p><p> /// </summary></p><p> public class MyPlugin : IPlugin, ISetupForm</p><p> {</p><p> #region ISetupForm</p><p> </p><p> public string PluginName()</p><p> {</p><p> return "MyPlugin";</p><p> }</p><p></p><p> public string Description()</p><p> {</p><p> return "This plugin shows how-to information for the current screen and selected item";</p><p> }</p><p></p><p> public string Author()</p><p> {</p><p> return "Me";</p><p> }</p><p></p><p> public void ShowPlugin()</p><p> {</p><p> throw new Exception("The method or operation is not implemented.");</p><p> }</p><p></p><p> public bool CanEnable()</p><p> {</p><p> return true;</p><p> }</p><p></p><p> public int GetWindowId()</p><p> {</p><p> return ( 1976 ) ;</p><p> }</p><p></p><p> public bool DefaultEnabled()</p><p> {</p><p> return true;</p><p> }</p><p></p><p> public bool HasSetup()</p><p> {</p><p> return false;</p><p> }</p><p></p><p> public bool GetHome(out string strButtonText, out string strButtonImage, out string strButtonImageFocus, out string strPictureImage)</p><p> {</p><p> LogInfo ( "GetHome" ) ;</p><p> </p><p> strButtonText = string.Empty ;</p><p> strButtonImage = string.Empty ;</p><p> strButtonImageFocus = string.Empty ;</p><p> strPictureImage = string.Empty ;</p><p> </p><p> return ( false ) ;</p><p> }</p><p> </p><p> #endregion</p><p></p><p> </p><p> /// <summary></p><p> /// </p><p> /// </summary></p><p> public void Start()</p><p> {</p><p> LogInfo ( "Start" ) ;</p><p> </p><p> System.Threading.Thread.Sleep ( 1000 ) ;</p><p> </p><p> try</p><p> {</p><p> GUIWindowManager.ActivateWindow ( ( int ) GUIWindow.Window.WINDOW_TVFULLSCREEN ) ;</p><p> }</p><p> </p><p> catch ( Exception exception )</p><p> {</p><p> LogInfo ( exception.Message ) ;</p><p> }</p><p> }</p><p></p><p> </p><p> /// <summary></p><p> /// </p><p> /// </summary></p><p> public void Stop()</p><p> {</p><p> LogInfo ( "Stopping" ) ;</p><p> }</p><p> </p><p> /// <summary></p><p> /// </p><p> /// </summary></p><p> /// <param name="message"></param></p><p> private void LogInfo ( string message )</p><p> {</p><p> Log.Info ( string.Format ( "########## {0} >>> {1}", this.PluginName(), message ) ) ;</p><p> }</p><p> }</p><p>}</p><p>[/CODE]</p></blockquote><p></p>
[QUOTE="WhyMe, post: 482903, member: 80405"] Hello la compagnie, le plugin AutoStart que j'ai tjs utilisé ne fonctionne plus avec la 1.1a ( çà devait bien arriver un jour ). Je me dis : je vais le recompiler et zou çà va repartir. Oui mais non : pas mal de chose on changé avec la 1.1a et impossible de recompiler le code. Alors je me dis : après tout je veux juste démarrer la télé à chaque démarrage de MP, spa compliqué, je vais faire un plugin tout neuf. J'ai donc un bout de code super compliqué qui marche pas :D La DLL est bien chargée, mais je ne passe pas ds le Start C'est un pb que j'avais déjà rencontré avec une version précédente de MP et un bout de code que j'avais fais pour tout autre chose, j'avais finis par débloquer le pb, mais je ne sais plus comment :( Une idée ? [CODE]2009-07-07 22:03:33.046875 [Info.][MPMain]: PlugInManager.Load() [B]2009-07-07 22:03:33.046875 [Info.][MPMain]: Load plugins from : C:\Program Files\Team MediaPortal\MediaPortal\Plugins\process\MyPlugin.dll 2009-07-07 22:03:33.062500 [Info.][MPMain]: File Version : 1.0.0.0 [/B]2009-07-07 22:03:33.062500 [Info.][MPMain]: Load plugins from : C:\Program Files\Team MediaPortal\MediaPortal\Plugins\process\ProcessPlugins.dll 2009-07-07 22:03:33.078125 [Info.][MPMain]: File Version : 1.0.3.23090 2009-07-07 22:03:33.078125 [Info.][MPMain]: PlugInManager.Start() 2009-07-07 22:03:33.890625 [Debug][MPMain]: d3dapp: ShowLastActiveModule active : False 2009-07-07 22:03:33.921875 [Info.][MPMain]: opening video database 2009-07-07 22:03:33.921875 [Info.][MPMain]: video database opened 2009-07-07 22:03:34.031250 [Info.][MPMain]: xml:C:\Documents and Settings\All Users\Application Data\Team MediaPortal\MediaPortal\Skin\Blue3wide\topbar.xml image id:1 width:0 height:0 gfx:empty.png 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:0 debug 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:1 font10 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:2 font11 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:3 font12 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:4 font13 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:5 font14 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:6 font15 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:7 font16 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:8 font17 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:9 font18 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:10 dingbats 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:11 font32 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:12 font48 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:13 font60 2009-07-07 22:03:44.421875 [Debug][MPMain]: GUIFont:texture disposing:14 fontSVT 2009-07-07 22:03:44.421875 [Info.][MPMain]: TexturePacker: disposing texture:1999 2009-07-07 22:03:44.421875 [Info.][MPMain]: TexturePacker: disposing texture:1998 2009-07-07 22:03:44.437500 [Info.][MPMain]: TexturePacker: disposing texture:1996 2009-07-07 22:03:44.453125 [Debug][MPMain]: TVHome: HeartBeat Transmitter stopped. 2009-07-07 22:03:44.468750 [Debug][MPMain]: Main: SaveLastActiveModule - enabled False 2009-07-07 22:03:44.468750 [Info.][MPMain]: Main: Exiting 2009-07-07 22:03:44.468750 [Info.][MPMain]: PlugInManager.Stop() [/CODE] [CODE]using System ; using System.Text ; using System.Collections ; using MediaPortal.GUI.Library ; namespace ProcessPlugins.MyPlugin { /// <summary> /// /// </summary> public class MyPlugin : IPlugin, ISetupForm { #region ISetupForm public string PluginName() { return "MyPlugin"; } public string Description() { return "This plugin shows how-to information for the current screen and selected item"; } public string Author() { return "Me"; } public void ShowPlugin() { throw new Exception("The method or operation is not implemented."); } public bool CanEnable() { return true; } public int GetWindowId() { return ( 1976 ) ; } public bool DefaultEnabled() { return true; } public bool HasSetup() { return false; } public bool GetHome(out string strButtonText, out string strButtonImage, out string strButtonImageFocus, out string strPictureImage) { LogInfo ( "GetHome" ) ; strButtonText = string.Empty ; strButtonImage = string.Empty ; strButtonImageFocus = string.Empty ; strPictureImage = string.Empty ; return ( false ) ; } #endregion /// <summary> /// /// </summary> public void Start() { LogInfo ( "Start" ) ; System.Threading.Thread.Sleep ( 1000 ) ; try { GUIWindowManager.ActivateWindow ( ( int ) GUIWindow.Window.WINDOW_TVFULLSCREEN ) ; } catch ( Exception exception ) { LogInfo ( exception.Message ) ; } } /// <summary> /// /// </summary> public void Stop() { LogInfo ( "Stopping" ) ; } /// <summary> /// /// </summary> /// <param name="message"></param> private void LogInfo ( string message ) { Log.Info ( string.Format ( "########## {0} >>> {1}", this.PluginName(), message ) ) ; } } } [/CODE] [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Language specific support
MediaPortal Forums Francais
MediaPortal 1 - Développement
Les plugins
Squelette de plugin
Contact us
RSS
Top
Bottom