public PluginInfo Initialise(IntPtr apiPtr)
        {
            Api = new MusicBeeApiInterface();
            Api.Initialise(apiPtr);
            Api.Player_SetScrobbleEnabled(false);

            Settings.Load();
            LastFm.Login(Settings.Key, Settings.Secret, Settings.Session);

            return(new PluginInfo {
                Type = PluginType.General,
                Name = "ScrobbleBee",
                Description = "Customizable scrobbling for MusicBee.",
                Author = "Karl Köörna",
                VersionMajor = 1,
                VersionMinor = 0,
                Revision = 1,
                PluginInfoVersion = PluginInfoVersion,
                MinInterfaceVersion = MinInterfaceVersion,
                MinApiRevision = MinApiRevision,
                ReceiveNotifications = ReceiveNotificationFlags.PlayerEvents | ReceiveNotificationFlags.TagEvents,
                ConfigurationPanelHeight = 0
            });
        }
Exemple #2
0
 /// <inheritdoc />
 public bool ToggleScrobbling()
 {
     return(_api.Player_SetScrobbleEnabled(!_api.Player_GetScrobbleEnabled()));
 }
 public void Uninstall()
 {
     Api.Player_SetScrobbleEnabled(true);
     Settings.Delete();
 }