Ejemplo n.º 1
0
        public SearchScreen()
        {
            this.Build();

            this.appContext       = AppContext.Default;
            yamsterCache          = appContext.YamsterCache;
            lblSearchResults.Text = "No search results.";

            messageView = new YamsterMessageView(appContext);
        }
Ejemplo n.º 2
0
        public GroupGrid()
        {
            this.Build();

            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            ctlGrid.ItemType = typeof(YamsterGroup);

            SetupColumns();

            ctlGrid.FormatCell        += ctlGrid_FormatCell;
            yamsterCache.GroupChanged += yamsterCache_GroupChanged;
        }
Ejemplo n.º 3
0
        public GroupConfigScreen()
        {
            this.Build();

            this.appContext = AppContext.Default;
            yamsterCache    = appContext.YamsterCache;

            reloadGroupsLagger = new ActionLagger(ReloadGroupsAction);
            reloadGroupsLagger.RequestAction();

            appContext.YamsterCache.GroupChanged += YamsterCache_GroupChanged;

            suspendEvents = false;
            UpdateUI();
        }
Ejemplo n.º 4
0
        public MessageGrid()
        {
            this.Build();

            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            ctlGrid.ItemType = typeof(YamsterMessage);

            SetupColumns();

            ctlGrid.Selection.Mode = SelectionMode.Multiple;
            ctlGrid.FormatCell    += ctlGrid_FormatCell;

            yamsterCache.MessageChanged += yamsterCache_MessageChanged;
        }
Ejemplo n.º 5
0
        public ConversationsScreen()
        {
            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            this.Build();

            ctlGrid.ItemType = typeof(YamsterConversation);
            SetupColumns();

            reloadConversationsLagger = new ActionLagger(ReloadConversationsAction, 1000);
            reloadConversationsLagger.RequestAction();

            ctlGrid.FilterDelegate = ctlGrid_Filter;

            this.yamsterCache.MessageChanged += yamsterCache_MessageChanged;
        }
Ejemplo n.º 6
0
        public GroupThreadScreen()
        {
            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            this.Build();

            ctlGroupGrid.Columns[GroupGridColumn.ShouldSync].Visible = false;
            ctlGroupGrid.Columns[GroupGridColumn.TrackRead].Visible  = false;

            reloadGroupsLagger  = new ActionLagger(ReloadGroupsAction);
            reloadThreadsLagger = new ActionLagger(ReloadThreadsAction);

            reloadGroupsLagger.RequestAction();

            yamsterCache.GroupChanged  += yamsterCache_GroupChanged;
            yamsterCache.ThreadChanged += yamsterCache_ThreadChanged;
        }
Ejemplo n.º 7
0
        public ThreadGrid()
        {
            this.Build();

            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            ctlGrid.ItemType = typeof(YamsterThread);

            SetupColumns();

            ctlGrid.Selection.Mode = Gtk.SelectionMode.Multiple;
            ctlGrid.FormatCell    += ctlGrid_FormatCell;

            yamsterCache.ThreadChanged += yamsterCache_ThreadChanged;

            UpdateUI();
        }
Ejemplo n.º 8
0
        public ThreadViewer()
        {
            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            this.Build();

            RebuildView();

            rebuildViewLagger = new ActionLagger(RebuildView);

            GLib.Timeout.Add(500, ProcessLoadingTimeout);

            yamsterCache.MessageChanged += YamsterCache_MessageChanged;
            yamsterCache.ThreadChanged  += YamsterCache_ThreadChanged;

            UpdateUI();
        }
Ejemplo n.º 9
0
        public UserChooserWindow()
            : base(Gtk.WindowType.Toplevel)
        {
            this.Build();

            // On Mac, this prevents the parent window from losing focus
            Debug.Assert(this.TypeHint == Gdk.WindowTypeHint.Normal);

            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            ctlGrid.ItemType = typeof(YamsterUser);

            SetupColumns();

            ctlGrid.FilterDelegate = ctlGrid_Filter;

            reloadLagger = new ActionLagger(ReloadAction, 100);
            reloadLagger.RequestAction(ActionLaggerQueueing.ForceDelayed);
        }
Ejemplo n.º 10
0
        public MainWindow()
            : base(Gtk.WindowType.Toplevel)
        {
            appContext   = AppContext.Default;
            yamsterCache = appContext.YamsterCache;

            MainWindow.ChatPaneWidth = appContext.Settings.ChatPaneWidth;

            Build();

            this.ctlChatPaneVBox.WidthRequest = MainWindow.ChatPaneWidth;

#if YAMSTER_MAC
            ctlMenuBar.Visible = false;
#endif
            ctlStatusBarMain.Push(0, "  Version " + Utilities.YamsterTerseVersion + "  -  https://github.com/octogonz/yamster");
            ctlStatusBarTotalYams.Push(0, "");
            SetStatusBarFormat(ctlStatusBarTotalYams, x => x.Xalign = 0.5f);
            ctlStatusBarSyncStatus.Push(0, "");
            SetStatusBarFormat(ctlStatusBarSyncStatus, x => x.Xalign = 0.5f);

            yamsterCache.MessageChanged += yamsterCache_MessageChanged;

            ctlViewsScreen.ThreadViewer         = ctlThreadViewer;
            ctlGroupThreadScreen.ThreadViewer   = ctlThreadViewer;
            ctlSearchScreen.ThreadViewer        = ctlThreadViewer;
            ctlConversationsScreen.ThreadViewer = ctlThreadViewer;

            ctlGroupConfigScreen.PerformLogin += ctlGroupConfigScreen_PerformLogin;

            updateStatusBarLagger = new ActionLagger(UpdateStatusBarAction);
            updateStatusBarLagger.RequestAction();

#if !DEBUG
            btnTest.Visible = false;
#endif
        }