Re: Web browser tabs, panel position, icons in the overview and a few more things.



On Fri, Nov 27, 2009 at 11:36:42AM -0800, Ivan Denker wrote:
> Are there plans to make the full width of the category names in the overview
> clickable, not just the little arrow on the right?

I'm having a go at implementing this, but my JS is not all that good,
and I don't really know the codebase that well. I've made a start, but
it doesn't actually do anything. I'd appreciate some of the people on
the list who know how this sort of thing works helping me out with this.

-- 
Josh Holland <jrh joshh co uk> (key F6067C12)
http://joshh.co.uk dutchie on irc.freenode.net
http://twitter.com/jshholland
http://identi.ca/jshholland
diff --git a/js/ui/dash.js b/js/ui/dash.js
index 1fc2184..c7e5988 100644
--- a/js/ui/dash.js
+++ b/js/ui/dash.js
@@ -478,6 +478,14 @@ Section.prototype = {
         this.content = new St.BoxLayout({ style_class: 'dash-section-content',
                                            vertical: true });
         this.actor.add(this.content);
+        this.actor.connect('button-press-event', Lang.bind(this, function (b, e) {
+            if (this.pane == null) {
+                // Ensure the pane is created; the activated handler will call setPane
+                this.emit('activated');
+            }
+            this._pane.toggle();
+            return true;
+        }));
     }
 }
 
@@ -622,7 +630,7 @@ Dash.prototype = {
         this._appsSection.content.add(appWell.actor, { expand: true });
 
         this._moreAppsPane = null;
-        this._appsSection.header.moreLink.connect('activated', Lang.bind(this, function (link) {
+        this._appsSection.header.connect('activated', Lang.bind(this, function (link) {
             if (this._moreAppsPane == null) {
                 this._moreAppsPane = new ResultPane(this);
                 this._moreAppsPane.packResults(APPS);
@@ -650,7 +658,7 @@ Dash.prototype = {
         this._docsSection.content.add(this._docDisplay.actor, { expand: true });
 
         this._moreDocsPane = null;
-        this._docsSection.header.moreLink.connect('activated', Lang.bind(this, function (link) {
+        this._docsSection.header.connect('activated', Lang.bind(this, function (link) {
             if (this._moreDocsPane == null) {
                 this._moreDocsPane = new ResultPane(this);
                 this._moreDocsPane.packResults(DOCS);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]