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
MediaPortal 1
Development
General Development (no feature request here!)
Powermenu: Standby/hibernate in singleseat - fix
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="styriaman" data-source="post: 222113" data-attributes="member: 10387"><p>Hi dev's</p><p></p><p>I fixed my problem described in <a href="https://forum.team-mediaportal.com/showpost.php?p=221366&postcount=14" target="_blank">https://forum.team-mediaportal.com/showpost.php?p=221366&postcount=14</a> by adding following bold line in ..\ClientPlugin\PowerScheduler.cs. </p><p></p><p> try</p><p> { </p><p> // persist the next wakeup datetime, this way 'resume last active module' feature is able to tell the difference between a wakeup done by </p><p> // a user or by the PS plugin</p><p> using (MediaPortal.Profile.Settings xmlwriter = new MediaPortal.Profile.Settings(Config.GetFile(Config.Dir.Config, "MediaPortal.xml")))</p><p> { </p><p> DateTime nextWakeUp = GetNextWakeupTime(DateTime.Now); </p><p> xmlwriter.SetValue("psclientplugin", "nextwakeup", nextWakeUp.ToString());</p><p> string res = xmlwriter.GetValueAsString("psclientplugin", "nextwakeup", DateTime.MaxValue.ToString());</p><p> }</p><p> <strong>RemotePowerControl.Instance.SuspendSystem("PowerSchedulerClientPlugin", (int)how, force);</strong></p><p> }</p><p> catch (Exception e)</p><p> {</p><p> Log.Error("PSClientPlugin: SuspendSystem failed! {0} {1}", e.Message, e.StackTrace);</p><p> }</p><p></p><p></p><p>Regards</p><p></p><p>Joe</p></blockquote><p></p>
[QUOTE="styriaman, post: 222113, member: 10387"] Hi dev's I fixed my problem described in [url]https://forum.team-mediaportal.com/showpost.php?p=221366&postcount=14[/url] by adding following bold line in ..\ClientPlugin\PowerScheduler.cs. try { // persist the next wakeup datetime, this way 'resume last active module' feature is able to tell the difference between a wakeup done by // a user or by the PS plugin using (MediaPortal.Profile.Settings xmlwriter = new MediaPortal.Profile.Settings(Config.GetFile(Config.Dir.Config, "MediaPortal.xml"))) { DateTime nextWakeUp = GetNextWakeupTime(DateTime.Now); xmlwriter.SetValue("psclientplugin", "nextwakeup", nextWakeUp.ToString()); string res = xmlwriter.GetValueAsString("psclientplugin", "nextwakeup", DateTime.MaxValue.ToString()); } [b]RemotePowerControl.Instance.SuspendSystem("PowerSchedulerClientPlugin", (int)how, force);[/b] } catch (Exception e) { Log.Error("PSClientPlugin: SuspendSystem failed! {0} {1}", e.Message, e.StackTrace); } Regards Joe [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 1
Development
General Development (no feature request here!)
Powermenu: Standby/hibernate in singleseat - fix
Contact us
RSS
Top
Bottom