NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public Add-ons (3rd party plugins, utilities and skins) Old Stuff (Legacy) GB-PVR Support (legacy) v
« Previous 1 … 215 216 217 218 219 … 1231 Next »
Can I change the display name of a plugin in the menu?

 
  • 0 Vote(s) - 0 Average
Can I change the display name of a plugin in the menu?
psycik
Offline

Posting Freak

Posts: 5,210
Threads: 424
Joined: Sep 2005
#11
2008-12-02, 08:56 PM
Because this is a community project, you can only ask developers do it, but not enforce it.

I can certainly add it to my stuff, if that infact is the problem..
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#12
2008-12-02, 09:20 PM
I provide a method to rename my Netflix plugin. Someone had requested it and I didn't know about the languages.xml so I added the functionality. If any other developers are interested, here's a generic modification of my method:

In the plugin's node section of config.xml, add a string element <PluginDisplayName>,

In the IMenuTask implementation, I have:
Code:
public override string getName()
        {
            System.Xml.XmlDocument s = new System.Xml.XmlDocument();
            try { s.Load("config.xml"); }
            catch { Logger.Error("Could not load config.xml"); }
            return ConfigFileUtilities.GetStringConfigSetting(s, "PluginNode", "PluginDisplayName", "My Plugin", false);
        }

This requires GBPVRCommonUtilities.dll but you can modify the last line to parse config.xml yourself so as to eliminate the dependency (something I keep meaning to do).
ACTCMS
Offline

Posting Freak

UK
Posts: 2,730
Threads: 101
Joined: Jun 2007
#13
2008-12-02, 09:28 PM
joshwake Wrote:I use gbpvr to play video and music for patients that come into my office, and I always get questions about where they should go for music, movies, etc.
You might need to be carefull here... this from the EULA
Quote:GRANT OF LICENSE: Subject to the following terms, devnz.com ("MENTEN HOLDINGS LTD") hereby grants you a non-exclusive, perpetual, non-transferable license to install and to use the GB-PVR software ("Software") for personal, non-commercial use.

Alex
psycik
Offline

Posting Freak

Posts: 5,210
Threads: 424
Joined: Sep 2005
#14
2008-12-02, 09:43 PM
whurlston Wrote:I provide a method to rename my Netflix plugin. Someone had requested it and I didn't know about the languages.xml so I added the functionality. If any other developers are interested, here's a generic modification of my method:

In the plugin's node section of config.xml, add a string element <PluginDisplayName>,

In the IMenuTask implementation, I have:
Code:
public override string getName()
        {
            System.Xml.XmlDocument s = new System.Xml.XmlDocument();
            try { s.Load("config.xml"); }
            catch { Logger.Error("Could not load config.xml"); }
            return ConfigFileUtilities.GetStringConfigSetting(s, "PluginNode", "PluginDisplayName", "My Plugin", false);
        }

This requires GBPVRCommonUtilities.dll but you can modify the last line to parse config.xml yourself so as to eliminate the dependency (something I keep meaning to do).


There used the be a pluginHelperFactory.getTranslation(string) method I think.. that you could use. I tend to use it on button names to they are translated on creation.
bgowland
Offline

Posting Freak

West Yorkshire, UK
Posts: 4,595
Threads: 387
Joined: Dec 2004
#15
2008-12-02, 11:20 PM (This post was last modified: 2008-12-02, 11:28 PM by bgowland.)
whurlston Wrote:This requires GBPVRCommonUtilities.dll but you can modify the last line to parse config.xml yourself so as to eliminate the dependency (something I keep meaning to do).
This works...
Code:
public override string getName()
{
    string DispName;
    XmlDocument s = new XmlDocument();
    try
    {
        s.Load("config.xml");
        DispName = s.SelectSingleNode("/settings/PluginSettings/MyPlugin/DisplayName").InnerText;
    }
    catch (Exception)
    {
        // Log something if you want but I'm not sure if there's any point.
        // Just catch any exception and set your default plugin name.
        DispName = "My Plugin";
    }
    return DispName;
}

psycik Wrote:There used the be a pluginHelperFactory.getTranslation(string) method I think.. that you could use. I tend to use it on button names to they are translated on creation.
This is part of SkinHelper2 but I'm not sure you could use it in the getName() method as this is also called by the Config app. in order to get the name to list on the Plugins tab.

I know for a fact that you can't use the PluginHelper in getName() as it only works within the pvrx2 framework. I'd suspect the same could be true for skinhelper2 but I don't know.

Cheers,
Brian
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#16
2008-12-03, 12:20 AM
bgowland Wrote:This works...
Yup. That would do it. (You do know I'm stealing it from you of course).
bgowland
Offline

Posting Freak

West Yorkshire, UK
Posts: 4,595
Threads: 387
Joined: Dec 2004
#17
2008-12-03, 12:38 AM
whurlston Wrote:(You do know I'm stealing it from you of course).
LOL - consider it a gift. Big Grin
dark_half
Offline

Senior Member

USA
Posts: 463
Threads: 30
Joined: Mar 2006
#18
2008-12-03, 02:22 AM
I edited SelectLanguage.XML and added
Code:
<language name="Jeff" file="language.jeff.xml"/>

I copied the Language.ENG.xml to Language.Jeff.xml and added among others to it
Code:
<translate originalText="Movie Wizard" translatedText="Movies"/>

then select Jeff as the language and this works for me.
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (2): « Previous 1 2


Possibly Related Threads…
Thread Author Replies Views Last Post
  STV HD change to S2 Pob 1 5,352 2013-06-10, 10:07 AM
Last Post: martint123
  What LCD Plugin or Utility to use these days? Snooze 66 23,347 2011-04-06, 02:51 AM
Last Post: Snooze
  Setting for Numeric Channel Change Timeout? smajor 6 2,890 2011-03-16, 07:21 PM
Last Post: sub
  UK Fiver change to 5* Dava 4 2,311 2011-03-14, 08:22 PM
Last Post: Dava
  Windows 7 and Working DVD Menu Navigation imilne 8 4,460 2011-01-04, 02:23 PM
Last Post: imilne
  Reset direct show on channel change? Pob 4 2,457 2010-12-06, 08:30 PM
Last Post: Pob
  IR Blaster doesn't change to channel missing show details Kid_Ego5150 3 2,123 2010-11-13, 02:11 AM
Last Post: sub
  TV Guide Display Problem (overlapping?) imgodot 2 2,176 2010-10-31, 05:53 AM
Last Post: imgodot
  Analog HD Recording Plugin To Record 16:9 Widescreen BTJustice 18 6,471 2010-09-12, 05:14 AM
Last Post: johnsonx42
  PVRX2.exe not rendering anything? no menu, video, nothing ClwFLGator 6 3,473 2010-08-24, 04:42 PM
Last Post: ClwFLGator

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode