[sawfish/sawfish-2.90] moved infinite-desktop.jl renamed two options improved infinite-desktop-enable updated for other cha
- From: Christopher Bratusek <chrisb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [sawfish/sawfish-2.90] moved infinite-desktop.jl renamed two options improved infinite-desktop-enable updated for other cha
- Date: Sun, 24 Oct 2010 17:15:20 +0000 (UTC)
commit 8d1a15483fc242e289669b654789e410081200fd
Author: Christopher Roy Bratusek <zanghar freenet de>
Date: Sun Oct 24 19:12:47 2010 +0200
moved infinite-desktop.jl
renamed two options
improved infinite-desktop-enable
updated for other changes
lisp/sawfish/wm/{ext => edge}/infinite-desktop.jl | 55 ++++++++++++---------
1 files changed, 31 insertions(+), 24 deletions(-)
---
diff --git a/lisp/sawfish/wm/ext/infinite-desktop.jl b/lisp/sawfish/wm/edge/infinite-desktop.jl
similarity index 72%
rename from lisp/sawfish/wm/ext/infinite-desktop.jl
rename to lisp/sawfish/wm/edge/infinite-desktop.jl
index 5d67b67..ff82ef0 100644
--- a/lisp/sawfish/wm/ext/infinite-desktop.jl
+++ b/lisp/sawfish/wm/edge/infinite-desktop.jl
@@ -18,7 +18,7 @@
;; along with sawfish; see the file COPYING. If not, write to
;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-(define-structure sawfish.wm.ext.infinite-desktop
+(define-structure sawfish.wm.edge.infinite-desktop
(export infinite-desktop-enable)
@@ -29,10 +29,11 @@
sawfish.wm.commands.move-cursor
sawfish.wm.viewport
sawfish.wm.util.prompt
- sawfish.wm.util.flippers
- sawfish.wm.ext.edge-flip)
+ sawfish.wm.edge.flippers
+ sawfish.wm.edge.util
+ sawfish.wm.edge.flip)
- (define-structure-alias infinite-desktop sawfish.wm.ext.infinite-desktop)
+ (define-structure-alias infinite-desktop sawfish.wm.edge.infinite-desktop)
(defgroup infinite-desktop "Infinite Desktop"
:group workspace)
@@ -43,25 +44,23 @@
:after-set (lambda () (infinite-desktop-enable))
:type boolean)
- ;;; NOTE: the `.' from the option will be removed during 2.90.0 cylce!
- (defcustom infinite-desktop.move-distance 64
+ (defcustom infinite-desktop-move-distance 64
"Amount to move the viewport when the pointer hits the screen edge."
:group (workspace infinite-desktop)
:type number
:range (1 . nil))
- ;;; NOTE: the `.' from the option will be removed during 2.90.0 cylce!
- (defcustom infinite-desktop.move-cursor-distance 32
+ (defcustom infinite-desktop-move-cursor-distance 32
"Amount to pull back the cursor after moving the viewport."
:group (workspace infinite-desktop)
:type number
:range (1 . nil))
(define (infinite-desktop-move-right)
- "Shifts the viewport `infinite-desktop.move-distance' pixels to the
+ "Shifts the viewport `infinite-desktop-move-distance' pixels to the
right."
- (let ((dist infinite-desktop.move-distance)
- (cdist infinite-desktop.move-cursor-distance)
+ (let ((dist infinite-desktop-move-distance)
+ (cdist infinite-desktop-move-cursor-distance)
(maxx (* (screen-width) (1- (car viewport-dimensions)))))
(if
(and (viewport-honor-workspace-edges)
@@ -71,10 +70,10 @@ right."
(move-cursor (- (min dist cdist)) 0)))
(define (infinite-desktop-move-left)
- "Shifts the viewport `infinite-desktop.move-distance' pixels to the
+ "Shifts the viewport `infinite-desktop-move-distance' pixels to the
left."
- (let ((dist (- infinite-desktop.move-distance))
- (cdist (- infinite-desktop.move-cursor-distance))
+ (let ((dist (- infinite-desktop-move-distance))
+ (cdist (- infinite-desktop-move-cursor-distance))
(minx 0))
(if
(and (viewport-honor-workspace-edges)
@@ -84,9 +83,9 @@ left."
(move-cursor (- (max dist cdist)) 0)))
(define (infinite-desktop-move-top)
- "Shifts the viewport `infinite-desktop.move-distance' pixels up."
- (let ((dist (- infinite-desktop.move-distance))
- (cdist (- infinite-desktop.move-cursor-distance))
+ "Shifts the viewport `infinite-desktop-move-distance' pixels up."
+ (let ((dist (- infinite-desktop-move-distance))
+ (cdist (- infinite-desktop-move-cursor-distance))
(miny 0))
(if
(and (viewport-honor-workspace-edges)
@@ -96,9 +95,9 @@ left."
(move-cursor 0 (- (max dist cdist)))))
(define (infinite-desktop-move-bottom)
- "Shifts the viewport `infinite-desktop.move-distance' pixels down."
- (let ((dist infinite-desktop.move-distance)
- (cdist infinite-desktop.move-cursor-distance)
+ "Shifts the viewport `infinite-desktop-move-distance' pixels down."
+ (let ((dist infinite-desktop-move-distance)
+ (cdist infinite-desktop-move-cursor-distance)
(maxy (* (screen-height) (1- (cdr viewport-dimensions)))))
(if
(and (viewport-honor-workspace-edges)
@@ -120,7 +119,15 @@ desktop."
(define (infinite-desktop-enable)
"Turn on infinite-desktop if `infinite-desktop-p' is true."
(if infinite-desktop-p
- (enable-flippers)))
-
- (unless batch-mode
- (add-hook 'enter-flipper-hook infinite-desktop-hook)))
+ (progn
+ (unless (in-hook-p 'enter-flipper-hook infinite-desktop-hook)
+ (add-hook 'enter-flipper-hook infinite-desktop-hook))
+ (unless edge-flip-enabled
+ (flippers-activate t)))
+ (if (in-hook-p 'enter-flipper-hook infinite-desktop-hook)
+ (remove-hook 'enter-flipper-hook infinite-desktop-hook)
+ (unless edge-flip-enabled
+ (flippers-activate nil)))))
+
+(unless batch-mode
+ (infinite-desktop-enable)))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]