CmisSync.Bubbles.Bubbles C# (CSharp) Method

Bubbles() public method

public Bubbles ( ) : System
return System
        public Bubbles ()
        {
            Controller.ShowBubbleEvent += delegate (string title, string subtext, string image_path) {
                InvokeOnMainThread (delegate {
                    if (NSApplication.SharedApplication.DockTile.BadgeLabel == null) {
                        NSApplication.SharedApplication.DockTile.BadgeLabel = "1";

                    } else {
                        int events = int.Parse (NSApplication.SharedApplication.DockTile.BadgeLabel);
                        NSApplication.SharedApplication.DockTile.BadgeLabel = (events + 1).ToString ();
                    }

                    if (image_path != null) {
                        NSData image_data = NSData.FromFile (image_path);
                        GrowlApplicationBridge.Notify (title, subtext, "Event", image_data, 0, false, new NSString (""));

                    } else {
                        GrowlApplicationBridge.Notify (title, subtext, "Event", null, 0, false, new NSString (""));
                    }
                });
            };
        }
    }
Bubbles