6 new, 4 modified for 1.3.5
[webos-internals:djcin7s-modifications.git] / app-launcher / app-launcher-reset-to-first-page.patch
1 --- /usr/lib/luna/system/luna-applauncher/app/controllers/launcher-assistant.js.orig    Sat Dec  5 11:48:12 2009
2 +++ /usr/lib/luna/system/luna-applauncher/app/controllers/launcher-assistant.js Thu Dec  3 19:42:03 2009
3 @@ -183,6 +183,16 @@
4                 delete this.launchRequest;
5                 
6                 this.removeLaunchFeedback();
7 +               
8 +               /* Reset launcher to first page */
9 +               $('launcher_root').mojo.setSnapIndex(0, false);
10 +               
11 +               /* Jump scroll position back to top for all pages */
12 +               var numPages=this.pagesModel.getNumPages();
13 +               for (var i=0; i<numPages; i++) {
14 +                       var scroller = this.getPageScroller(i);
15 +                       if (scroller && scroller.mojo) { scroller.mojo.revealTop(); }
16 +               }
17         },
18         
19         onResize: function(event) {