public Browser()
: base(WindowType.Toplevel)
{
Title = "Summa";
IconName = "summa";
action_group = new Gtk.ActionGroup("general");
factory = new IconFactory();
factory.AddDefault();
DestroyEvent += CloseWindow;
DeleteEvent += CloseWindow;
SetUpActionGroup();
uimanager = new UIManager();
uimanager.InsertActionGroup(action_group, 0);
AddAccelGroup(uimanager.AccelGroup);
SetUpUimanager();
table = new Table(5, 5, false);
Add(table);
menubar = uimanager.GetWidget("/MenuBar");
table.Attach(menubar, 0, 5, 0, 1, AttachOptions.Fill, AttachOptions.Fill, 0, 0);
toolbar = uimanager.GetWidget("/ToolBar");
table.Attach(toolbar, 0, 5, 1, 2, AttachOptions.Fill, AttachOptions.Fill, 0, 0);
main_paned = new HPaned();
table.Attach(main_paned, 0, 5, 2, 3);
left_paned = new VPaned();
main_paned.Pack1(left_paned, true, true);
TagView = new TagView();
TagView.CursorChanged += new EventHandler(TagviewChanged);
TagView_swin = new ScrolledWindow(new Adjustment(0, 0, 0, 0, 0, 0), new Adjustment(0, 0, 0, 0, 0, 0));
TagView_swin.Add(TagView);
TagView_swin.ShadowType = ShadowType.In;
TagView_swin.SetPolicy(PolicyType.Automatic, PolicyType.Automatic);
left_paned.Pack1(TagView_swin, true, true);
FeedView = new FeedView();
FeedView.CursorChanged += new EventHandler(FeedviewChanged);
FeedView_swin = new ScrolledWindow(new Adjustment(0, 0, 0, 0, 0, 0), new Adjustment(0, 0, 0, 0, 0, 0));
FeedView_swin.Add(FeedView);
FeedView_swin.ShadowType = ShadowType.In;
FeedView_swin.SetPolicy(PolicyType.Automatic, PolicyType.Automatic);
left_paned.Pack2(FeedView_swin, true, true);
if ( Config.WidescreenView ) {
right_paned = new HPaned();
} else {
right_paned = new VPaned();
}
main_paned.Pack2(right_paned, true, true);
ItemView = new ItemView();
ItemView.CursorChanged += new EventHandler(ItemviewChanged);
ItemView_swin = new ScrolledWindow(new Adjustment(0, 0, 0, 0, 0, 0), new Adjustment(0, 0, 0, 0, 0, 0));
ItemView_swin.Add(ItemView);
ItemView_swin.ShadowType = ShadowType.In;
ItemView_swin.SetPolicy(PolicyType.Automatic, PolicyType.Automatic);
right_paned.Pack1(ItemView_swin, true, true);
ItemNotebook = new ItemNotebook();
right_paned.Pack2(ItemNotebook, true, true);
StatusBar = new NotificationBar();
table.Attach(StatusBar, 0, 5, 3, 4, AttachOptions.Fill, AttachOptions.Fill, 0, 0);
UpdateFromConfig();
FeedView.Populate("All");
Database.ItemChanged += OnItemChanged;
Database.ItemAdded += OnItemAdded;
Notifier.ViewChanged += OnViewChanged;
}