summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: e6f18ad)
raw | patch | inline | side by side (parent: e6f18ad)
author | buliabyak <buliabyak@users.sourceforge.net> | |
Mon, 6 Nov 2006 06:50:58 +0000 (06:50 +0000) | ||
committer | buliabyak <buliabyak@users.sourceforge.net> | |
Mon, 6 Nov 2006 06:50:58 +0000 (06:50 +0000) |
src/gradient-context.cpp | patch | blob | history | |
src/gradient-context.h | patch | blob | history | |
src/verbs.cpp | patch | blob | history |
index f97bd93c821e81f26dce66a00a65d6099fd8ce19..ad1dd873066873f5e58d2ee198837464c1f5b9c5 100644 (file)
--- a/src/gradient-context.cpp
+++ b/src/gradient-context.cpp
rc->_message_context = new Inkscape::MessageContext(sp_desktop_message_stack(ec->desktop));
}
+void
+sp_gradient_context_select_next (SPEventContext *event_context)
+{
+ GrDrag *drag = event_context->_grdrag;
+ g_assert (drag);
+
+ drag->select_next();
+}
+
+void
+sp_gradient_context_select_prev (SPEventContext *event_context)
+{
+ GrDrag *drag = event_context->_grdrag;
+ g_assert (drag);
+
+ drag->select_prev();
+}
+
static gint sp_gradient_context_root_handler(SPEventContext *event_context, GdkEvent *event)
{
static bool dragging;
@@ -274,19 +292,6 @@ static gint sp_gradient_context_root_handler(SPEventContext *event_context, GdkE
//TODO: make dragging escapable by Esc
break;
- case GDK_Tab: // Tab - cycle selection forward
- if (!(MOD__CTRL_ONLY || (MOD__CTRL && MOD__SHIFT))) {
- drag->select_next();
- ret = TRUE;
- }
- break;
- case GDK_ISO_Left_Tab: // Shift Tab - cycle selection backward
- if (!(MOD__CTRL_ONLY || (MOD__CTRL && MOD__SHIFT))) {
- drag->select_prev();
- ret = TRUE;
- }
- break;
-
case GDK_Left: // move handle left
case GDK_KP_Left:
case GDK_KP_4:
diff --git a/src/gradient-context.h b/src/gradient-context.h
index 3eb7910f8ff6a0c02833e79cb03f546aa1b7903c..80dfecd3a5a3762fa56047d8d295086cdd6bd3fe 100644 (file)
--- a/src/gradient-context.h
+++ b/src/gradient-context.h
};
/* Standard Gtk function */
-
GtkType sp_gradient_context_get_type();
+void sp_gradient_context_select_next (SPEventContext *event_context);
+void sp_gradient_context_select_prev (SPEventContext *event_context);
+
#endif
diff --git a/src/verbs.cpp b/src/verbs.cpp
index 1495c1f9e32db4e23e3dcf106883c24be61dbc72..4721de9d5e686525991d78e31c790f070039af77 100644 (file)
--- a/src/verbs.cpp
+++ b/src/verbs.cpp
#include "sp-flowtext.h"
#include "layer-fns.h"
#include "node-context.h"
+#include "gradient-context.h"
/**
case SP_VERB_EDIT_SELECT_NEXT:
if (tools_isactive(dt, TOOLS_NODES)) {
sp_nodepath_select_next(SP_NODE_CONTEXT(ec)->nodepath);
+ } else if (tools_isactive(dt, TOOLS_GRADIENT)) {
+ sp_gradient_context_select_next (ec);
} else {
sp_selection_item_next();
}
case SP_VERB_EDIT_SELECT_PREV:
if (tools_isactive(dt, TOOLS_NODES)) {
sp_nodepath_select_prev(SP_NODE_CONTEXT(ec)->nodepath);
+ } else if (tools_isactive(dt, TOOLS_GRADIENT)) {
+ sp_gradient_context_select_prev (ec);
} else {
sp_selection_item_prev();
}