~lubuntu-software-center-team/lubuntu-software-center/vala-port

« back to all changes in this revision

Viewing changes to src/Frontend.vala

  • Committer: Stephen Smally
  • Date: 2012-07-05 13:49:59 UTC
  • Revision ID: eco.stefi@fastwebnet.it-20120705134959-y5vg66cadej8vix1
Added mutable install/remove button

Show diffs side-by-side

added added

removed removed

Lines of Context:
121
121
        }
122
122
        
123
123
        public void update_back_button (Notebook nb, Widget pg, uint page_n) {
124
 
            stdout.printf("Page->%s\n", ((PageType) page_n).to_string());
 
124
            GLib.debug ("Page->%s\n", ((PageType) page_n).to_string());
125
125
            switch ((PageType) page_n) {
126
126
                case PageType.HOMEPAGE:
127
127
                    toolbar.searchbar.set_sensitive(true);
167
167
            pages_view.switch_page.connect(update_back_button);
168
168
            pages_view.switch_page.connect(toolbar.update_label);
169
169
            // When back is clicked
170
 
            toolbar.back.clicked.connect(on_back_clicked);
 
170
            toolbar.back.button_press_event.connect(on_back_clicked);
171
171
        }
172
172
        
173
173
        public void rework_categories_columns () {
175
175
                return;
176
176
            }
177
177
            if (_width != get_allocated_width() && get_allocated_width()/150 != pages_view.home_page.categories_view.columns) {
178
 
                stdout.printf("Window.width->%d rework columns\n", get_allocated_width());
 
178
                GLib.debug ("Window.width->%d rework columns\n", get_allocated_width());
179
179
                int size = get_allocated_width();
180
180
                if (size < 150 ) {
181
181
                    size = 150;
190
190
            rework_categories_columns();
191
191
        }
192
192
        
193
 
        public void on_back_clicked (ToolButton button) {
 
193
        public bool on_back_clicked (Widget box, Gdk.EventButton button) {
194
194
                        switch (pages_view.get_current_page()) {
195
195
                                case PageType.APPSVIEW:
196
196
                                    back_to_homepage();
202
202
                                default:
203
203
                                    break;
204
204
                        }
 
205
                        
 
206
                        return true;
205
207
                }
206
208
        
207
209
        public void on_load_started (LoadingType load, string comment) {