You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2013/11/15 15:00:42 UTC

git commit: ISIS-588: small bookmark panel, and keyboard shortcut.

Updated Branches:
  refs/heads/master a3c11b300 -> cc9b45f46


ISIS-588: small bookmark panel, and keyboard shortcut.

I've chosen alt+] as the keyboard shortcut.
Perhaps this ought to be configurable, but it isn't at the moment.


Project: http://git-wip-us.apache.org/repos/asf/isis/repo
Commit: http://git-wip-us.apache.org/repos/asf/isis/commit/cc9b45f4
Tree: http://git-wip-us.apache.org/repos/asf/isis/tree/cc9b45f4
Diff: http://git-wip-us.apache.org/repos/asf/isis/diff/cc9b45f4

Branch: refs/heads/master
Commit: cc9b45f46a2a605b9b8634fc62d4dcdcd8f2447f
Parents: a3c11b3
Author: Dan Haywood <da...@apache.org>
Authored: Fri Nov 15 13:59:42 2013 +0000
Committer: Dan Haywood <da...@apache.org>
Committed: Fri Nov 15 13:59:42 2013 +0000

----------------------------------------------------------------------
 .../bookmarkedpages/BookmarkedPagesPanel.css    |  2 +-
 .../components/bookmarkedpages/slide-panel.js   | 20 +++++++++++++++++++-
 2 files changed, 20 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/isis/blob/cc9b45f4/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/BookmarkedPagesPanel.css
----------------------------------------------------------------------
diff --git a/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/BookmarkedPagesPanel.css b/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/BookmarkedPagesPanel.css
index 4071d88..2fac53a 100644
--- a/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/BookmarkedPagesPanel.css
+++ b/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/BookmarkedPagesPanel.css
@@ -98,7 +98,7 @@
 .showPanelTab {
     border-radius: 0px 8px 8px 0px;
 	width:10px;
-    height:720px;
+    height:200px;
     position:fixed;
     left:0px;
     top:120px;

http://git-wip-us.apache.org/repos/asf/isis/blob/cc9b45f4/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/slide-panel.js
----------------------------------------------------------------------
diff --git a/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/slide-panel.js b/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/slide-panel.js
index bd638b2..1968489 100644
--- a/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/slide-panel.js
+++ b/component/viewer/wicket/ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/bookmarkedpages/slide-panel.js
@@ -32,9 +32,27 @@ $(document).ready(function(){
             function() { 
                 $('#bookmarkedPagesSlidingDiv').stop().animate({width:"0", opacity:0.1}, 0);
             });
-         $('.showPanelTab').animate({opacity: 1.0});
+        $('.showPanelTab').animate({opacity: 1.0});
      };
 
+     var hideBookmarksQuickly = function(){
+         $('.content').hide();
+         $('#bookmarkedPagesSlidingDiv').css({width:"0"}, 0);
+         $('.showPanelTab').css({opacity: 1.0});
+      };
+
     $('.showPanelTab').mouseenter(showBookmarks);
     $('#bookmarkedPagesSlidingDiv').mouseleave(hideBookmarks);
+    
+    $('body').keydown(function(e) {
+        
+        // alt+]
+        if(e.which === 221 && e.altKey) {
+            if($('#bookmarkedPagesSlidingDiv .content').is(":visible")) {
+                hideBookmarksQuickly();
+            } else {
+                showBookmarks();
+            }
+        }
+      });
 });
\ No newline at end of file