summaryrefslogtreecommitdiffstats
path: root/shared/src
diff options
context:
space:
mode:
Diffstat (limited to 'shared/src')
-rw-r--r--shared/src/com/vaadin/shared/ui/grid/GridConstants.java15
-rw-r--r--shared/src/com/vaadin/shared/ui/grid/GridServerRpc.java25
-rw-r--r--shared/src/com/vaadin/shared/ui/grid/GridState.java8
3 files changed, 46 insertions, 2 deletions
diff --git a/shared/src/com/vaadin/shared/ui/grid/GridConstants.java b/shared/src/com/vaadin/shared/ui/grid/GridConstants.java
index 0606e4b1cc..5b2ac96975 100644
--- a/shared/src/com/vaadin/shared/ui/grid/GridConstants.java
+++ b/shared/src/com/vaadin/shared/ui/grid/GridConstants.java
@@ -74,4 +74,19 @@ public final class GridConstants implements Serializable {
/** The default cancel button caption in the editor */
public static final String DEFAULT_CANCEL_CAPTION = "Cancel";
+
+ /**
+ * Event ID constant for editor open event
+ */
+ public static final String EDITOR_OPEN_EVENT_ID = "editorOpen";
+
+ /**
+ * Event ID constant for editor move event
+ */
+ public static final String EDITOR_MOVE_EVENT_ID = "editorMove";
+
+ /**
+ * Event ID constant for editor close event
+ */
+ public static final String EDITOR_CLOSE_EVENT_ID = "editorClose";
}
diff --git a/shared/src/com/vaadin/shared/ui/grid/GridServerRpc.java b/shared/src/com/vaadin/shared/ui/grid/GridServerRpc.java
index dca55c11c4..99b339765a 100644
--- a/shared/src/com/vaadin/shared/ui/grid/GridServerRpc.java
+++ b/shared/src/com/vaadin/shared/ui/grid/GridServerRpc.java
@@ -37,6 +37,31 @@ public interface GridServerRpc extends ServerRpc {
boolean userOriginated);
/**
+ * Informs the server that the editor was opened (fresh) on a certain row
+ *
+ * @param rowKey
+ * a key identifying item the editor was opened on
+ */
+ void editorOpen(String rowKey);
+
+ /**
+ * Informs the server that the editor was reopened (without closing it in
+ * between) on another row
+ *
+ * @param rowKey
+ * a key identifying item the editor was opened on
+ */
+ void editorMove(String rowKey);
+
+ /**
+ * Informs the server that the editor was closed
+ *
+ * @param rowKey
+ * a key identifying item the editor was opened on
+ */
+ void editorClose(String rowKey);
+
+ /**
* Informs the server that an item has been clicked in Grid.
*
* @param rowKey
diff --git a/shared/src/com/vaadin/shared/ui/grid/GridState.java b/shared/src/com/vaadin/shared/ui/grid/GridState.java
index c23c931683..c4121cbf45 100644
--- a/shared/src/com/vaadin/shared/ui/grid/GridState.java
+++ b/shared/src/com/vaadin/shared/ui/grid/GridState.java
@@ -19,9 +19,9 @@ package com.vaadin.shared.ui.grid;
import java.util.ArrayList;
import java.util.List;
-import com.vaadin.shared.AbstractComponentState;
import com.vaadin.shared.annotations.DelegateToWidget;
import com.vaadin.shared.data.sort.SortDirection;
+import com.vaadin.shared.ui.TabIndexState;
/**
* The shared state for the {@link com.vaadin.ui.components.grid.Grid} component
@@ -29,7 +29,7 @@ import com.vaadin.shared.data.sort.SortDirection;
* @since 7.4
* @author Vaadin Ltd
*/
-public class GridState extends AbstractComponentState {
+public class GridState extends TabIndexState {
/**
* A description of which of the three bundled SelectionModels is currently
@@ -156,6 +156,10 @@ public class GridState extends AbstractComponentState {
/** The enabled state of the editor interface */
public boolean editorEnabled = false;
+ /** Buffered editor mode */
+ @DelegateToWidget
+ public boolean editorBuffered = true;
+
/** Whether row data might contain generated row styles */
public boolean hasRowStyleGenerator;
/** Whether row data might contain generated cell styles */