diff options
author | Artur Signell <artur@vaadin.com> | 2016-08-18 23:27:29 +0300 |
---|---|---|
committer | Artur Signell <artur@vaadin.com> | 2016-08-22 20:08:25 +0300 |
commit | 8328038b3c695da27f6247fc9b33ed97c0e0d771 (patch) | |
tree | c9d69b66fc37c27e93f82342506c62d8e9845cb2 /compatibility-client/src | |
parent | a6873053f005c195c5e43211761c5f936be14a4e (diff) | |
download | vaadin-framework-8328038b3c695da27f6247fc9b33ed97c0e0d771.tar.gz vaadin-framework-8328038b3c695da27f6247fc9b33ed97c0e0d771.zip |
Rename packages in compatibility-client to use com.vaadin.v7
Change-Id: Id0f178dfc3910ee7492c860d381b2d413e82ba73
Diffstat (limited to 'compatibility-client/src')
108 files changed, 839 insertions, 223 deletions
diff --git a/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyDateFieldConnector.java b/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyDateFieldConnector.java deleted file mode 100644 index ee62b03588..0000000000 --- a/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyDateFieldConnector.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2000-2016 Vaadin Ltd. - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not - * use this file except in compliance with the License. You may obtain a copy of - * the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations under - * the License. - */ -package com.vaadin.client.v7.ui; - -import com.vaadin.client.ui.datefield.DateFieldConnector; -import com.vaadin.shared.ui.Connect; -import com.vaadin.v7.ui.DateField; - -/** - * @author Vaadin Ltd - * - */ -@Connect(DateField.class) -@Deprecated -public class LegacyDateFieldConnector extends DateFieldConnector { - -} diff --git a/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyInlineDateFieldConnector.java b/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyInlineDateFieldConnector.java deleted file mode 100644 index 60459ff9c0..0000000000 --- a/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyInlineDateFieldConnector.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2000-2016 Vaadin Ltd. - * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not - * use this file except in compliance with the License. You may obtain a copy of - * the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT - * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the - * License for the specific language governing permissions and limitations under - * the License. - */ -package com.vaadin.client.v7.ui; - -import com.vaadin.client.ui.datefield.InlineDateFieldConnector; -import com.vaadin.shared.ui.Connect; -import com.vaadin.v7.ui.InlineDateField; - -/** - * @author Vaadin Ltd - * - */ -@Connect(InlineDateField.class) -@Deprecated -public class LegacyInlineDateFieldConnector extends InlineDateFieldConnector { - -} diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/AbstractGridRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/AbstractGridRendererConnector.java index 7824e41dd7..0a7c8b68ef 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/AbstractGridRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/AbstractGridRendererConnector.java @@ -13,9 +13,10 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.client.ServerConnector; +import com.vaadin.client.connectors.AbstractRendererConnector; import com.vaadin.client.renderers.Renderer; import com.vaadin.client.widgets.Grid.Column; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/AbstractSelectionModelConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/AbstractSelectionModelConnector.java index 75664d04f9..c1a0cf9123 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/AbstractSelectionModelConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/AbstractSelectionModelConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import java.util.Collection; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/ButtonRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ButtonRendererConnector.java index d0d2b6196b..df59418326 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/ButtonRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ButtonRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.google.web.bindery.event.shared.HandlerRegistration; import com.vaadin.client.renderers.ButtonRenderer; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/ClickableRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ClickableRendererConnector.java index 89549bc2bc..3049fa9883 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/ClickableRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ClickableRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.google.web.bindery.event.shared.HandlerRegistration; import com.vaadin.client.MouseEventDetailsBuilder; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/DateRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/DateRendererConnector.java index 4eb56376f4..ced67b7f21 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/DateRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/DateRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.shared.ui.Connect; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/DetailComponentManagerConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/DetailComponentManagerConnector.java index 49874c84b4..5da620423a 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/DetailComponentManagerConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/DetailComponentManagerConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.client.ServerConnector; import com.vaadin.client.extensions.AbstractExtensionConnector; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/GridConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/GridConnector.java index b30557885a..1bf3d7a8ea 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/GridConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/GridConnector.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import java.util.ArrayList; import java.util.Arrays; @@ -46,8 +46,6 @@ import com.vaadin.client.TooltipInfo; import com.vaadin.client.WidgetUtil; import com.vaadin.client.communication.StateChangeEvent; import com.vaadin.client.communication.StateChangeEvent.StateChangeHandler; -import com.vaadin.client.connectors.RpcDataSourceConnector.DetailsListener; -import com.vaadin.client.connectors.RpcDataSourceConnector.RpcDataSource; import com.vaadin.client.ui.AbstractComponentConnector; import com.vaadin.client.ui.AbstractHasComponentsConnector; import com.vaadin.client.ui.ConnectorFocusAndBlurHandler; @@ -95,6 +93,8 @@ import com.vaadin.shared.ui.grid.GridStaticSectionState; import com.vaadin.shared.ui.grid.GridStaticSectionState.CellState; import com.vaadin.shared.ui.grid.GridStaticSectionState.RowState; import com.vaadin.shared.ui.grid.ScrollDestination; +import com.vaadin.v7.client.connectors.RpcDataSourceConnector.DetailsListener; +import com.vaadin.v7.client.connectors.RpcDataSourceConnector.RpcDataSource; import elemental.json.JsonObject; import elemental.json.JsonValue; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/ImageRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ImageRendererConnector.java index d71cb28a7d..092e01e626 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/ImageRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ImageRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.google.web.bindery.event.shared.HandlerRegistration; import com.vaadin.client.communication.JsonDecoder; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/JavaScriptRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/JavaScriptRendererConnector.java index 4bd618dacd..7213b6a846 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/JavaScriptRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/JavaScriptRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import java.util.ArrayList; import java.util.Collection; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/MultiSelectionModelConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/MultiSelectionModelConnector.java index 7a13863a9e..ac52a02056 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/MultiSelectionModelConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/MultiSelectionModelConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import java.util.ArrayList; import java.util.Arrays; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/NoSelectionModelConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/NoSelectionModelConnector.java index b3fbb16e6b..bbbd462ab5 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/NoSelectionModelConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/NoSelectionModelConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.client.ServerConnector; import com.vaadin.client.widget.grid.selection.SelectionModel; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/NumberRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/NumberRendererConnector.java index 6383594ca2..13fa0602cd 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/NumberRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/NumberRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.shared.ui.Connect; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/ProgressBarRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ProgressBarRendererConnector.java index 57bafc69ba..0fda3114ec 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/ProgressBarRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/ProgressBarRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.client.renderers.ProgressBarRenderer; import com.vaadin.shared.ui.Connect; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/RpcDataSourceConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/RpcDataSourceConnector.java index d33cf72a33..5eee892616 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/RpcDataSourceConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/RpcDataSourceConnector.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import java.util.ArrayList; import java.util.Collections; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/SingleSelectionModelConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/SingleSelectionModelConnector.java index 84f0633e9b..0e6702027e 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/SingleSelectionModelConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/SingleSelectionModelConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.client.ServerConnector; import com.vaadin.client.annotations.OnStateChange; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/TextRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/TextRendererConnector.java index faa09fda13..03775ec6f0 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/TextRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/TextRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.client.renderers.TextRenderer; import com.vaadin.shared.ui.Connect; diff --git a/compatibility-client/src/main/java/com/vaadin/client/connectors/UnsafeHtmlRendererConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/UnsafeHtmlRendererConnector.java index 8888c1041b..36f58e302b 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/connectors/UnsafeHtmlRendererConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/connectors/UnsafeHtmlRendererConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.connectors; +package com.vaadin.v7.client.connectors; import com.vaadin.client.renderers.Renderer; import com.vaadin.client.widget.grid.RendererCellReference; diff --git a/compatibility-client/src/main/java/com/vaadin/v7/client/ui/JsniMousewheelHandler.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/JsniMousewheelHandler.java new file mode 100644 index 0000000000..56b56ef40f --- /dev/null +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/JsniMousewheelHandler.java @@ -0,0 +1,75 @@ +/* + * Copyright 2000-2016 Vaadin Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not + * use this file except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ +package com.vaadin.v7.client.ui; + +import com.google.gwt.core.client.JavaScriptObject; +import com.google.gwt.dom.client.Element; +import com.google.gwt.user.client.Event; +import com.google.gwt.user.client.ui.Widget; +import com.vaadin.client.widgets.Escalator; + +/** + * A mousewheel handling class to get around the limits of + * {@link Event#ONMOUSEWHEEL}. + * + * For internal use only. May be removed or replaced in the future. + * + * @see Escalator.JsniWorkaround + */ +abstract class JsniMousewheelHandler { + + /** + * A JavaScript function that handles the mousewheel DOM event, and passes + * it on to Java code. + * + * @see #createMousewheelListenerFunction(Widget) + */ + protected final JavaScriptObject mousewheelListenerFunction; + + protected JsniMousewheelHandler(final Widget widget) { + mousewheelListenerFunction = createMousewheelListenerFunction(widget); + } + + /** + * A method that constructs the JavaScript function that will be stored into + * {@link #mousewheelListenerFunction}. + * + * @param widget + * a reference to the current instance of {@link Widget} + */ + protected abstract JavaScriptObject createMousewheelListenerFunction( + Widget widget); + + public native void attachMousewheelListener(Element element) + /*-{ + if (element.addEventListener) { + // FireFox likes "wheel", while others use "mousewheel" + var eventName = 'onmousewheel' in element ? 'mousewheel' : 'wheel'; + element.addEventListener(eventName, this.@com.vaadin.v7.client.ui.JsniMousewheelHandler::mousewheelListenerFunction); + } + }-*/; + + public native void detachMousewheelListener(Element element) + /*-{ + if (element.addEventListener) { + // FireFox likes "wheel", while others use "mousewheel" + var eventName = element.onwheel===undefined?"mousewheel":"wheel"; + element.removeEventListener(eventName, this.@com.vaadin.v7.client.ui.JsniMousewheelHandler::mousewheelListenerFunction); + } + }-*/; + +} + diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/VCalendar.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VCalendar.java index 8414d7c99c..dbe42ce1e9 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/VCalendar.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VCalendar.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui; +package com.vaadin.v7.client.ui; import java.util.ArrayList; import java.util.Arrays; @@ -30,18 +30,18 @@ import com.google.gwt.user.client.ui.Composite; import com.google.gwt.user.client.ui.DockPanel; import com.google.gwt.user.client.ui.ScrollPanel; import com.google.gwt.user.client.ui.Widget; -import com.vaadin.client.ui.calendar.schedule.CalendarDay; -import com.vaadin.client.ui.calendar.schedule.CalendarEvent; -import com.vaadin.client.ui.calendar.schedule.DayToolbar; -import com.vaadin.client.ui.calendar.schedule.MonthGrid; -import com.vaadin.client.ui.calendar.schedule.SimpleDayCell; -import com.vaadin.client.ui.calendar.schedule.SimpleDayToolbar; -import com.vaadin.client.ui.calendar.schedule.SimpleWeekToolbar; -import com.vaadin.client.ui.calendar.schedule.WeekGrid; -import com.vaadin.client.ui.calendar.schedule.WeeklyLongEvents; -import com.vaadin.client.ui.calendar.schedule.dd.CalendarDropHandler; import com.vaadin.client.ui.dd.VHasDropHandler; import com.vaadin.shared.ui.calendar.DateConstants; +import com.vaadin.v7.client.ui.calendar.schedule.CalendarDay; +import com.vaadin.v7.client.ui.calendar.schedule.CalendarEvent; +import com.vaadin.v7.client.ui.calendar.schedule.DayToolbar; +import com.vaadin.v7.client.ui.calendar.schedule.MonthGrid; +import com.vaadin.v7.client.ui.calendar.schedule.SimpleDayCell; +import com.vaadin.v7.client.ui.calendar.schedule.SimpleDayToolbar; +import com.vaadin.v7.client.ui.calendar.schedule.SimpleWeekToolbar; +import com.vaadin.v7.client.ui.calendar.schedule.WeekGrid; +import com.vaadin.v7.client.ui.calendar.schedule.WeeklyLongEvents; +import com.vaadin.v7.client.ui.calendar.schedule.dd.CalendarDropHandler; /** * Client side implementation for Calendar diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/VFilterSelect.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VFilterSelect.java index 814767e19f..adf360ccdb 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/VFilterSelect.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VFilterSelect.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui; +package com.vaadin.v7.client.ui; import java.util.ArrayList; import java.util.Collection; @@ -71,17 +71,22 @@ import com.vaadin.client.DeferredWorker; import com.vaadin.client.Focusable; import com.vaadin.client.VConsole; import com.vaadin.client.WidgetUtil; +import com.vaadin.client.ui.Field; +import com.vaadin.client.ui.Icon; +import com.vaadin.client.ui.SubPartAware; +import com.vaadin.client.ui.VLazyExecutor; +import com.vaadin.client.ui.VOverlay; import com.vaadin.client.ui.aria.AriaHelper; import com.vaadin.client.ui.aria.HandlesAriaCaption; import com.vaadin.client.ui.aria.HandlesAriaInvalid; import com.vaadin.client.ui.aria.HandlesAriaRequired; -import com.vaadin.client.ui.combobox.ComboBoxConnector; import com.vaadin.client.ui.menubar.MenuBar; import com.vaadin.client.ui.menubar.MenuItem; import com.vaadin.shared.AbstractComponentState; import com.vaadin.shared.ui.ComponentStateUtil; import com.vaadin.shared.ui.combobox.FilteringMode; import com.vaadin.shared.util.SharedUtil; +import com.vaadin.v7.client.ui.combobox.ComboBoxConnector; /** * Client side implementation of the Select component. @@ -182,8 +187,9 @@ public class VFilterSelect extends Composite /** * Gets the style set for this suggestion item. Styles are typically set - * by a server-side {@link com.vaadin.v7.ui.ComboBox.ItemStyleGenerator}. - * The returned style is prefixed by <code>v-filterselect-item-</code>. + * by a server-side + * {@link com.vaadin.v7.ui.ComboBox.ItemStyleGenerator}. The returned + * style is prefixed by <code>v-filterselect-item-</code>. * * @since 7.5.6 * @return the style name to use, or <code>null</code> to not apply any @@ -247,7 +253,7 @@ public class VFilterSelect extends Composite deltaY = -0.5*e.wheelDelta; } - @com.vaadin.client.ui.VFilterSelect.JsniUtil::moveScrollFromEvent(*)(widget, deltaX, deltaY, e, e.deltaMode); + @com.vaadin.v7.client.ui.VFilterSelect.JsniUtil::moveScrollFromEvent(*)(widget, deltaX, deltaY, e, e.deltaMode); }); }-*/; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/VRichTextArea.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VRichTextArea.java index 6814543f50..a00ff78e9d 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/VRichTextArea.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VRichTextArea.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui; +package com.vaadin.v7.client.ui; import java.util.HashMap; import java.util.Map; @@ -38,8 +38,11 @@ import com.google.gwt.user.client.ui.Widget; import com.vaadin.client.ApplicationConnection; import com.vaadin.client.BrowserInfo; import com.vaadin.client.ConnectorMap; +import com.vaadin.client.ui.Field; +import com.vaadin.client.ui.ShortcutActionHandler; +import com.vaadin.client.ui.TouchScrollDelegate; import com.vaadin.client.ui.ShortcutActionHandler.ShortcutActionHandlerOwner; -import com.vaadin.client.ui.richtextarea.VRichTextToolbar; +import com.vaadin.v7.client.ui.richtextarea.VRichTextToolbar; /** * This class implements a basic client side rich text editor component. diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/VScrollTable.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VScrollTable.java index 24ea202189..d15ae0b9fa 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/VScrollTable.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VScrollTable.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui; +package com.vaadin.v7.client.ui; import java.util.ArrayList; import java.util.Collection; @@ -93,7 +93,17 @@ import com.vaadin.client.Util; import com.vaadin.client.VConsole; import com.vaadin.client.VTooltip; import com.vaadin.client.WidgetUtil; -import com.vaadin.client.ui.VScrollTable.VScrollTableBody.VScrollTableRow; +import com.vaadin.client.ui.Action; +import com.vaadin.client.ui.ActionOwner; +import com.vaadin.client.ui.FocusableScrollPanel; +import com.vaadin.client.ui.Icon; +import com.vaadin.client.ui.SubPartAware; +import com.vaadin.client.ui.TouchScrollDelegate; +import com.vaadin.client.ui.TreeAction; +import com.vaadin.client.ui.VContextMenu; +import com.vaadin.client.ui.VEmbedded; +import com.vaadin.client.ui.VLabel; +import com.vaadin.client.ui.VOverlay; import com.vaadin.client.ui.dd.DDUtil; import com.vaadin.client.ui.dd.VAbstractDropHandler; import com.vaadin.client.ui.dd.VAcceptCallback; @@ -107,6 +117,7 @@ import com.vaadin.shared.MouseEventDetails; import com.vaadin.shared.ui.dd.VerticalDropLocation; import com.vaadin.shared.ui.table.CollapseMenuContent; import com.vaadin.shared.ui.table.TableConstants; +import com.vaadin.v7.client.ui.VScrollTable.VScrollTableBody.VScrollTableRow; /** * VScrollTable diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/VTextArea.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VTextArea.java index 6ad69fb9cb..bb79a852cf 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/VTextArea.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VTextArea.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui; +package com.vaadin.v7.client.ui; import com.google.gwt.core.client.Scheduler; import com.google.gwt.dom.client.Element; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/VTree.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VTree.java index f9101a5e30..cb07c0b8be 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/VTree.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VTree.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui; +package com.vaadin.v7.client.ui; import java.util.ArrayList; import java.util.HashMap; @@ -61,6 +61,13 @@ import com.vaadin.client.MouseEventDetailsBuilder; import com.vaadin.client.UIDL; import com.vaadin.client.Util; import com.vaadin.client.WidgetUtil; +import com.vaadin.client.ui.Action; +import com.vaadin.client.ui.ActionOwner; +import com.vaadin.client.ui.FocusElementPanel; +import com.vaadin.client.ui.Icon; +import com.vaadin.client.ui.SubPartAware; +import com.vaadin.client.ui.TreeAction; +import com.vaadin.client.ui.VLazyExecutor; import com.vaadin.client.ui.aria.AriaHelper; import com.vaadin.client.ui.aria.HandlesAriaCaption; import com.vaadin.client.ui.dd.DDUtil; @@ -71,12 +78,12 @@ import com.vaadin.client.ui.dd.VDragEvent; import com.vaadin.client.ui.dd.VDropHandler; import com.vaadin.client.ui.dd.VHasDropHandler; import com.vaadin.client.ui.dd.VTransferable; -import com.vaadin.client.ui.tree.TreeConnector; import com.vaadin.shared.MouseEventDetails; import com.vaadin.shared.MouseEventDetails.MouseButton; import com.vaadin.shared.ui.MultiSelectMode; import com.vaadin.shared.ui.dd.VerticalDropLocation; import com.vaadin.shared.ui.tree.TreeConstants; +import com.vaadin.v7.client.ui.tree.TreeConnector; /** * diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/VTreeTable.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VTreeTable.java index 25a9d4e29b..db691b3785 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/VTreeTable.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/VTreeTable.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui; +package com.vaadin.v7.client.ui; import java.util.ArrayList; import java.util.Iterator; @@ -38,7 +38,8 @@ import com.google.gwt.user.client.ui.Widget; import com.vaadin.client.ComputedStyle; import com.vaadin.client.UIDL; import com.vaadin.client.WidgetUtil; -import com.vaadin.client.ui.VTreeTable.VTreeTableScrollBody.VTreeTableRow; +import com.vaadin.client.ui.Icon; +import com.vaadin.v7.client.ui.VTreeTable.VTreeTableScrollBody.VTreeTableRow; public class VTreeTable extends VScrollTable { diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/CalendarConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/CalendarConnector.java index 8f6118eed6..6ce348d0d0 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/CalendarConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/CalendarConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar; +package com.vaadin.v7.client.ui.calendar; import java.text.ParseException; import java.util.ArrayList; @@ -43,28 +43,6 @@ import com.vaadin.client.ui.AbstractComponentConnector; import com.vaadin.client.ui.Action; import com.vaadin.client.ui.ActionOwner; import com.vaadin.client.ui.SimpleManagedLayout; -import com.vaadin.client.ui.VCalendar; -import com.vaadin.client.ui.VCalendar.BackwardListener; -import com.vaadin.client.ui.VCalendar.DateClickListener; -import com.vaadin.client.ui.VCalendar.EventClickListener; -import com.vaadin.client.ui.VCalendar.EventMovedListener; -import com.vaadin.client.ui.VCalendar.EventResizeListener; -import com.vaadin.client.ui.VCalendar.ForwardListener; -import com.vaadin.client.ui.VCalendar.MouseEventListener; -import com.vaadin.client.ui.VCalendar.RangeSelectListener; -import com.vaadin.client.ui.VCalendar.WeekClickListener; -import com.vaadin.client.ui.calendar.schedule.CalendarDay; -import com.vaadin.client.ui.calendar.schedule.CalendarEvent; -import com.vaadin.client.ui.calendar.schedule.DateCell; -import com.vaadin.client.ui.calendar.schedule.DateCell.DateCellSlot; -import com.vaadin.client.ui.calendar.schedule.DateCellDayEvent; -import com.vaadin.client.ui.calendar.schedule.DateUtil; -import com.vaadin.client.ui.calendar.schedule.HasTooltipKey; -import com.vaadin.client.ui.calendar.schedule.MonthEventLabel; -import com.vaadin.client.ui.calendar.schedule.SimpleDayCell; -import com.vaadin.client.ui.calendar.schedule.dd.CalendarDropHandler; -import com.vaadin.client.ui.calendar.schedule.dd.CalendarMonthDropHandler; -import com.vaadin.client.ui.calendar.schedule.dd.CalendarWeekDropHandler; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.Connect.LoadStyle; import com.vaadin.shared.ui.calendar.CalendarClientRpc; @@ -72,6 +50,28 @@ import com.vaadin.shared.ui.calendar.CalendarEventId; import com.vaadin.shared.ui.calendar.CalendarServerRpc; import com.vaadin.shared.ui.calendar.CalendarState; import com.vaadin.shared.ui.calendar.DateConstants; +import com.vaadin.v7.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar.BackwardListener; +import com.vaadin.v7.client.ui.VCalendar.DateClickListener; +import com.vaadin.v7.client.ui.VCalendar.EventClickListener; +import com.vaadin.v7.client.ui.VCalendar.EventMovedListener; +import com.vaadin.v7.client.ui.VCalendar.EventResizeListener; +import com.vaadin.v7.client.ui.VCalendar.ForwardListener; +import com.vaadin.v7.client.ui.VCalendar.MouseEventListener; +import com.vaadin.v7.client.ui.VCalendar.RangeSelectListener; +import com.vaadin.v7.client.ui.VCalendar.WeekClickListener; +import com.vaadin.v7.client.ui.calendar.schedule.CalendarDay; +import com.vaadin.v7.client.ui.calendar.schedule.CalendarEvent; +import com.vaadin.v7.client.ui.calendar.schedule.DateCell; +import com.vaadin.v7.client.ui.calendar.schedule.DateCellDayEvent; +import com.vaadin.v7.client.ui.calendar.schedule.DateUtil; +import com.vaadin.v7.client.ui.calendar.schedule.HasTooltipKey; +import com.vaadin.v7.client.ui.calendar.schedule.MonthEventLabel; +import com.vaadin.v7.client.ui.calendar.schedule.SimpleDayCell; +import com.vaadin.v7.client.ui.calendar.schedule.DateCell.DateCellSlot; +import com.vaadin.v7.client.ui.calendar.schedule.dd.CalendarDropHandler; +import com.vaadin.v7.client.ui.calendar.schedule.dd.CalendarMonthDropHandler; +import com.vaadin.v7.client.ui.calendar.schedule.dd.CalendarWeekDropHandler; import com.vaadin.v7.ui.Calendar; /** diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/VCalendarAction.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/VCalendarAction.java index f16a43fbb2..a5c54e5c4a 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/VCalendarAction.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/VCalendarAction.java @@ -13,15 +13,15 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar; +package com.vaadin.v7.client.ui.calendar; import java.util.Date; import com.google.gwt.i18n.client.DateTimeFormat; import com.vaadin.client.ui.Action; -import com.vaadin.client.ui.calendar.schedule.CalendarEvent; import com.vaadin.shared.ui.calendar.CalendarServerRpc; import com.vaadin.shared.ui.calendar.DateConstants; +import com.vaadin.v7.client.ui.calendar.schedule.CalendarEvent; /** * Action performed by the calendar diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/CalendarDay.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/CalendarDay.java index c2ade39a6d..20cbfe17ab 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/CalendarDay.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/CalendarDay.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; /** * Utility class used to represent a day when updating views. Only used diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/CalendarEvent.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/CalendarEvent.java index 937b7c0ccb..dfb84f3788 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/CalendarEvent.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/CalendarEvent.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCell.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCell.java index 2590c4ed03..92e6f20345 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCell.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCell.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.ArrayList; import java.util.Date; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCellContainer.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCellContainer.java index 92c39c0791..81366922c2 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCellContainer.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCellContainer.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; @@ -24,7 +24,7 @@ import com.google.gwt.event.dom.client.MouseUpHandler; import com.google.gwt.user.client.ui.FlowPanel; import com.google.gwt.user.client.ui.Widget; import com.vaadin.client.WidgetUtil; -import com.vaadin.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar; /** * Internally used class by the Calendar diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCellDayEvent.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCellDayEvent.java index 7404f557a8..52c4e56a21 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCellDayEvent.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCellDayEvent.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; import java.util.LinkedList; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCellGroup.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCellGroup.java index 907a71c449..af1e1ed9a1 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateCellGroup.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateCellGroup.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.ArrayList; import java.util.Date; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateUtil.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateUtil.java index 4a11e95245..b8abb31262 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DateUtil.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DateUtil.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DayToolbar.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DayToolbar.java index 0ba1023945..4d7d1631c2 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/DayToolbar.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/DayToolbar.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Iterator; @@ -24,7 +24,7 @@ import com.google.gwt.user.client.ui.Button; import com.google.gwt.user.client.ui.HorizontalPanel; import com.google.gwt.user.client.ui.Label; import com.google.gwt.user.client.ui.Widget; -import com.vaadin.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar; /** * diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/FocusableComplexPanel.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/FocusableComplexPanel.java index a498525c92..86ff8f280f 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/FocusableComplexPanel.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/FocusableComplexPanel.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import com.google.gwt.event.dom.client.BlurEvent; import com.google.gwt.event.dom.client.BlurHandler; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/FocusableGrid.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/FocusableGrid.java index fd46f5553b..7faae676a2 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/FocusableGrid.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/FocusableGrid.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import com.google.gwt.event.dom.client.BlurEvent; import com.google.gwt.event.dom.client.BlurHandler; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/FocusableHTML.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/FocusableHTML.java index 3a838a58a3..a09cc996dd 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/FocusableHTML.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/FocusableHTML.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import com.google.gwt.event.dom.client.BlurEvent; import com.google.gwt.event.dom.client.BlurHandler; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/HasTooltipKey.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/HasTooltipKey.java index 936f978abb..f33fdb55a7 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/HasTooltipKey.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/HasTooltipKey.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; /** * For Calendar client-side internal use only. diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/MonthEventLabel.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/MonthEventLabel.java index c62b21592a..042c007794 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/MonthEventLabel.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/MonthEventLabel.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; @@ -21,7 +21,7 @@ import com.google.gwt.event.dom.client.ContextMenuEvent; import com.google.gwt.event.dom.client.ContextMenuHandler; import com.google.gwt.user.client.ui.HTML; import com.vaadin.client.Util; -import com.vaadin.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar; /** * The label in a month cell diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/MonthGrid.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/MonthGrid.java index 119fe27992..c5efcb9feb 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/MonthGrid.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/MonthGrid.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; @@ -21,7 +21,7 @@ import com.google.gwt.event.dom.client.KeyCodes; import com.google.gwt.event.dom.client.KeyDownEvent; import com.google.gwt.event.dom.client.KeyDownHandler; import com.google.gwt.event.shared.HandlerRegistration; -import com.vaadin.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar; /** * diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/SimpleDayCell.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/SimpleDayCell.java index 45ae5ed8e5..eb206824ec 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/SimpleDayCell.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/SimpleDayCell.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; @@ -38,8 +38,8 @@ import com.google.gwt.user.client.ui.HTML; import com.google.gwt.user.client.ui.Label; import com.google.gwt.user.client.ui.Widget; import com.vaadin.client.ui.FocusableFlowPanel; -import com.vaadin.client.ui.VCalendar; import com.vaadin.shared.ui.calendar.DateConstants; +import com.vaadin.v7.client.ui.VCalendar; /** * A class representing a single cell within the calendar in month-view diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/SimpleDayToolbar.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/SimpleDayToolbar.java index e83a2cce3a..4c745f39c1 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/SimpleDayToolbar.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/SimpleDayToolbar.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import com.google.gwt.user.client.ui.HorizontalPanel; import com.google.gwt.user.client.ui.Label; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/SimpleWeekToolbar.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/SimpleWeekToolbar.java index 30c52e1059..5ca670fbf5 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/SimpleWeekToolbar.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/SimpleWeekToolbar.java @@ -13,12 +13,12 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import com.google.gwt.event.dom.client.ClickEvent; import com.google.gwt.event.dom.client.ClickHandler; import com.google.gwt.user.client.ui.FlexTable; -import com.vaadin.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar; /** * diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeekGrid.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeekGrid.java index cfc9d6231a..687333e4b8 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeekGrid.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeekGrid.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Arrays; import java.util.Date; @@ -32,8 +32,8 @@ import com.google.gwt.user.client.ui.SimplePanel; import com.google.gwt.user.client.ui.Widget; import com.vaadin.client.DateTimeService; import com.vaadin.client.WidgetUtil; -import com.vaadin.client.ui.VCalendar; import com.vaadin.shared.ui.calendar.DateConstants; +import com.vaadin.v7.client.ui.VCalendar; /** * diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeekGridMinuteTimeRange.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeekGridMinuteTimeRange.java index 984d3d48dc..ac413917d5 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeekGridMinuteTimeRange.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeekGridMinuteTimeRange.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeekLabel.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeekLabel.java index ae7001cb21..5f609b87fe 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeekLabel.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeekLabel.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import com.google.gwt.user.client.ui.Label; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeeklyLongEvents.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeeklyLongEvents.java index fe1f3e181e..4ed86b0b68 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeeklyLongEvents.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeeklyLongEvents.java @@ -13,13 +13,13 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; import java.util.List; import com.google.gwt.user.client.ui.HorizontalPanel; -import com.vaadin.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar; /** * diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeeklyLongEventsDateCell.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeeklyLongEventsDateCell.java index a098ab9c1a..01f602fdd7 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/WeeklyLongEventsDateCell.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/WeeklyLongEventsDateCell.java @@ -13,12 +13,12 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule; +package com.vaadin.v7.client.ui.calendar.schedule; import java.util.Date; import com.google.gwt.user.client.ui.HTML; -import com.vaadin.client.ui.VCalendar; +import com.vaadin.v7.client.ui.VCalendar; /** * Represents a cell used in {@link WeeklyLongEvents} diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/dd/CalendarDropHandler.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/dd/CalendarDropHandler.java index 58757b8552..22e65c80f4 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/dd/CalendarDropHandler.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/dd/CalendarDropHandler.java @@ -13,11 +13,11 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule.dd; +package com.vaadin.v7.client.ui.calendar.schedule.dd; import com.vaadin.client.ApplicationConnection; -import com.vaadin.client.ui.calendar.CalendarConnector; import com.vaadin.client.ui.dd.VAbstractDropHandler; +import com.vaadin.v7.client.ui.calendar.CalendarConnector; /** * Abstract base class for calendar drop handlers. diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/dd/CalendarMonthDropHandler.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/dd/CalendarMonthDropHandler.java index 663ee1eb98..fcc0326343 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/dd/CalendarMonthDropHandler.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/dd/CalendarMonthDropHandler.java @@ -13,15 +13,15 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule.dd; +package com.vaadin.v7.client.ui.calendar.schedule.dd; import com.google.gwt.dom.client.Element; import com.google.gwt.user.client.DOM; import com.vaadin.client.WidgetUtil; -import com.vaadin.client.ui.calendar.CalendarConnector; -import com.vaadin.client.ui.calendar.schedule.SimpleDayCell; import com.vaadin.client.ui.dd.VAcceptCallback; import com.vaadin.client.ui.dd.VDragEvent; +import com.vaadin.v7.client.ui.calendar.CalendarConnector; +import com.vaadin.v7.client.ui.calendar.schedule.SimpleDayCell; /** * Handles DD when the monthly view is showing in the Calendar. In the monthly diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/dd/CalendarWeekDropHandler.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/dd/CalendarWeekDropHandler.java index c0ad635ef7..fdc60671b7 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/calendar/schedule/dd/CalendarWeekDropHandler.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/calendar/schedule/dd/CalendarWeekDropHandler.java @@ -13,16 +13,16 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.calendar.schedule.dd; +package com.vaadin.v7.client.ui.calendar.schedule.dd; import com.google.gwt.dom.client.Element; import com.google.gwt.user.client.DOM; import com.vaadin.client.WidgetUtil; -import com.vaadin.client.ui.calendar.CalendarConnector; -import com.vaadin.client.ui.calendar.schedule.DateCell; -import com.vaadin.client.ui.calendar.schedule.DateCellDayEvent; import com.vaadin.client.ui.dd.VAcceptCallback; import com.vaadin.client.ui.dd.VDragEvent; +import com.vaadin.v7.client.ui.calendar.CalendarConnector; +import com.vaadin.v7.client.ui.calendar.schedule.DateCell; +import com.vaadin.v7.client.ui.calendar.schedule.DateCellDayEvent; /** * Handles DD when the weekly view is showing in the Calendar. In the weekly diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/AbstractColorPickerConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/AbstractColorPickerConnector.java index 6f480538e0..59db8dc659 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/AbstractColorPickerConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/AbstractColorPickerConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.colorpicker; +package com.vaadin.v7.client.ui.colorpicker; import com.google.gwt.event.dom.client.ClickHandler; import com.google.gwt.event.dom.client.HasClickHandlers; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerAreaConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerAreaConnector.java index 6c1bee17a0..4426fc815f 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerAreaConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerAreaConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.colorpicker; +package com.vaadin.v7.client.ui.colorpicker; import com.google.gwt.core.client.GWT; import com.google.gwt.event.dom.client.ClickEvent; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerConnector.java index cc917a044e..c9f78259cb 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.colorpicker; +package com.vaadin.v7.client.ui.colorpicker; import com.google.gwt.core.client.GWT; import com.google.gwt.event.dom.client.ClickEvent; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerGradientConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerGradientConnector.java index 98ebfa086c..29343b7eb2 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerGradientConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerGradientConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.colorpicker; +package com.vaadin.v7.client.ui.colorpicker; import com.google.gwt.core.client.GWT; import com.google.gwt.event.dom.client.MouseUpEvent; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerGridConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerGridConnector.java index b842154e40..889e25df33 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/ColorPickerGridConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/ColorPickerGridConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.colorpicker; +package com.vaadin.v7.client.ui.colorpicker; import com.google.gwt.core.client.GWT; import com.google.gwt.event.dom.client.ClickEvent; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/VColorPickerGradient.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/VColorPickerGradient.java index b75bee23c1..d62be14fd1 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/VColorPickerGradient.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/VColorPickerGradient.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.colorpicker; +package com.vaadin.v7.client.ui.colorpicker; import com.google.gwt.dom.client.Style.Unit; import com.google.gwt.event.dom.client.MouseDownEvent; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/VColorPickerGrid.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/VColorPickerGrid.java index 67f2ce07dd..18b31e41e9 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/colorpicker/VColorPickerGrid.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/colorpicker/VColorPickerGrid.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.colorpicker; +package com.vaadin.v7.client.ui.colorpicker; import com.google.gwt.dom.client.Element; import com.google.gwt.event.dom.client.ClickEvent; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/combobox/ComboBoxConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/combobox/ComboBoxConnector.java index 672e428802..4a632b9071 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/combobox/ComboBoxConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/combobox/ComboBoxConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.combobox; +package com.vaadin.v7.client.ui.combobox; import java.util.ArrayList; import java.util.Iterator; @@ -27,14 +27,14 @@ import com.vaadin.client.communication.RpcProxy; import com.vaadin.client.communication.StateChangeEvent; import com.vaadin.client.ui.AbstractFieldConnector; import com.vaadin.client.ui.SimpleManagedLayout; -import com.vaadin.client.ui.VFilterSelect; -import com.vaadin.client.ui.VFilterSelect.DataReceivedHandler; -import com.vaadin.client.ui.VFilterSelect.FilterSelectSuggestion; import com.vaadin.shared.EventId; import com.vaadin.shared.communication.FieldRpc.FocusAndBlurServerRpc; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.combobox.ComboBoxServerRpc; import com.vaadin.shared.ui.combobox.ComboBoxState; +import com.vaadin.v7.client.ui.VFilterSelect; +import com.vaadin.v7.client.ui.VFilterSelect.DataReceivedHandler; +import com.vaadin.v7.client.ui.VFilterSelect.FilterSelectSuggestion; import com.vaadin.v7.ui.ComboBox; @Connect(ComboBox.class) diff --git a/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/AbstractDateFieldConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/AbstractDateFieldConnector.java new file mode 100644 index 0000000000..e5da960a9d --- /dev/null +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/AbstractDateFieldConnector.java @@ -0,0 +1,122 @@ +/* + * Copyright 2000-2016 Vaadin Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not + * use this file except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ +package com.vaadin.v7.client.ui.datefield; + +import java.util.Date; + +import com.vaadin.client.ApplicationConnection; +import com.vaadin.client.LocaleNotLoadedException; +import com.vaadin.client.Paintable; +import com.vaadin.client.UIDL; +import com.vaadin.client.VConsole; +import com.vaadin.client.ui.AbstractFieldConnector; +import com.vaadin.client.ui.VDateField; +import com.vaadin.shared.ui.datefield.DateFieldConstants; +import com.vaadin.shared.ui.datefield.Resolution; + +public class AbstractDateFieldConnector extends AbstractFieldConnector + implements Paintable { + + @Override + public void updateFromUIDL(UIDL uidl, ApplicationConnection client) { + if (!isRealUpdate(uidl)) { + return; + } + + // Save details + getWidget().client = client; + getWidget().paintableId = uidl.getId(); + getWidget().immediate = getState().immediate; + + getWidget().setReadonly(isReadOnly()); + getWidget().setEnabled(isEnabled()); + + if (uidl.hasAttribute("locale")) { + final String locale = uidl.getStringAttribute("locale"); + try { + getWidget().dts.setLocale(locale); + getWidget().setCurrentLocale(locale); + } catch (final LocaleNotLoadedException e) { + getWidget().setCurrentLocale(getWidget().dts.getLocale()); + VConsole.error("Tried to use an unloaded locale \"" + locale + + "\". Using default locale (" + + getWidget().getCurrentLocale() + ")."); + VConsole.error(e); + } + } + + // We show week numbers only if the week starts with Monday, as ISO 8601 + // specifies + getWidget().setShowISOWeekNumbers( + uidl.getBooleanAttribute(DateFieldConstants.ATTR_WEEK_NUMBERS) + && getWidget().dts.getFirstDayOfWeek() == 1); + + Resolution newResolution; + if (uidl.hasVariable("sec")) { + newResolution = Resolution.SECOND; + } else if (uidl.hasVariable("min")) { + newResolution = Resolution.MINUTE; + } else if (uidl.hasVariable("hour")) { + newResolution = Resolution.HOUR; + } else if (uidl.hasVariable("day")) { + newResolution = Resolution.DAY; + } else if (uidl.hasVariable("month")) { + newResolution = Resolution.MONTH; + } else { + newResolution = Resolution.YEAR; + } + + // Remove old stylename that indicates current resolution + setWidgetStyleName( + getWidget().getStylePrimaryName() + "-" + VDateField + .resolutionToString(getWidget().getCurrentResolution()), + false); + + getWidget().setCurrentResolution(newResolution); + + // Add stylename that indicates current resolution + setWidgetStyleName( + getWidget().getStylePrimaryName() + "-" + VDateField + .resolutionToString(getWidget().getCurrentResolution()), + true); + + final Resolution resolution = getWidget().getCurrentResolution(); + final int year = uidl.getIntVariable("year"); + final int month = (resolution.getCalendarField() >= Resolution.MONTH + .getCalendarField()) ? uidl.getIntVariable("month") : -1; + final int day = (resolution.getCalendarField() >= Resolution.DAY + .getCalendarField()) ? uidl.getIntVariable("day") : -1; + final int hour = (resolution.getCalendarField() >= Resolution.HOUR + .getCalendarField()) ? uidl.getIntVariable("hour") : 0; + final int min = (resolution.getCalendarField() >= Resolution.MINUTE + .getCalendarField()) ? uidl.getIntVariable("min") : 0; + final int sec = (resolution.getCalendarField() >= Resolution.SECOND + .getCalendarField()) ? uidl.getIntVariable("sec") : 0; + + // Construct new date for this datefield (only if not null) + if (year > -1) { + getWidget().setCurrentDate(new Date((long) getWidget().getTime(year, + month, day, hour, min, sec, 0))); + } else { + getWidget().setCurrentDate(null); + } + } + + @Override + public VDateField getWidget() { + return (VDateField) super.getWidget(); + } +} diff --git a/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/DateFieldConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/DateFieldConnector.java new file mode 100644 index 0000000000..7d81df987b --- /dev/null +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/DateFieldConnector.java @@ -0,0 +1,216 @@ +/* + * Copyright 2000-2016 Vaadin Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not + * use this file except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ + +package com.vaadin.v7.client.ui.datefield; + +import java.util.Date; + +import com.google.gwt.event.logical.shared.CloseEvent; +import com.google.gwt.event.logical.shared.CloseHandler; +import com.google.gwt.user.client.ui.PopupPanel; +import com.vaadin.client.ApplicationConnection; +import com.vaadin.client.DateTimeService; +import com.vaadin.client.UIDL; +import com.vaadin.client.communication.StateChangeEvent; +import com.vaadin.client.ui.VCalendarPanel.FocusChangeListener; +import com.vaadin.client.ui.VCalendarPanel.TimeChangeListener; +import com.vaadin.client.ui.VPopupCalendar; +import com.vaadin.shared.ui.Connect; +import com.vaadin.shared.ui.datefield.PopupDateFieldState; +import com.vaadin.shared.ui.datefield.Resolution; +import com.vaadin.v7.ui.DateField; + +@Connect(DateField.class) +public class DateFieldConnector extends TextualDateConnector { + + @Override + protected void init() { + getWidget().popup.addCloseHandler(new CloseHandler<PopupPanel>() { + + @Override + public void onClose(CloseEvent<PopupPanel> event) { + /* + * FIXME This is a hack so we do not have to rewrite half of the + * datefield so values are not sent while selecting a date + * (#6252). + * + * The datefield will now only set the date UIDL variables while + * the user is selecting year/month/date/time and not send them + * directly. Only when the user closes the popup (by clicking on + * a day/enter/clicking outside of popup) then the new value is + * communicated to the server. + */ + if (getWidget().isImmediate()) { + getConnection().getServerRpcQueue().flush(); + } + } + }); + } + + /* + * (non-Javadoc) + * + * @see com.vaadin.client.ui.VTextualDate#updateFromUIDL(com.vaadin + * .client.UIDL, com.vaadin.client.ApplicationConnection) + */ + @Override + @SuppressWarnings("deprecation") + public void updateFromUIDL(UIDL uidl, ApplicationConnection client) { + + String oldLocale = getWidget().getCurrentLocale(); + + getWidget().parsable = uidl.getBooleanAttribute("parsable"); + + super.updateFromUIDL(uidl, client); + + getWidget().calendar + .setDateTimeService(getWidget().getDateTimeService()); + getWidget().calendar + .setShowISOWeekNumbers(getWidget().isShowISOWeekNumbers()); + if (getWidget().calendar.getResolution() != getWidget() + .getCurrentResolution()) { + boolean hasSelectedDate = false; + getWidget().calendar + .setResolution(getWidget().getCurrentResolution()); + if (getWidget().calendar.getDate() != null + && getWidget().getCurrentDate() != null) { + hasSelectedDate = true; + getWidget().calendar + .setDate((Date) getWidget().getCurrentDate().clone()); + } + // force re-render when changing resolution only + getWidget().calendar.renderCalendar(hasSelectedDate); + } + + // Force re-render of calendar if locale has changed (#12153) + if (!getWidget().getCurrentLocale().equals(oldLocale)) { + getWidget().calendar.renderCalendar(); + } + + if (getWidget().getCurrentResolution() + .getCalendarField() <= Resolution.MONTH.getCalendarField()) { + getWidget().calendar + .setFocusChangeListener(new FocusChangeListener() { + @Override + public void focusChanged(Date date) { + + getWidget().updateValue(date); + getWidget().buildDate(); + Date date2 = getWidget().calendar.getDate(); + date2.setYear(date.getYear()); + date2.setMonth(date.getMonth()); + } + }); + } else { + getWidget().calendar.setFocusChangeListener(null); + } + + if (getWidget().getCurrentResolution() + .getCalendarField() > Resolution.DAY.getCalendarField()) { + getWidget().calendar + .setTimeChangeListener(new TimeChangeListener() { + @Override + public void changed(int hour, int min, int sec, + int msec) { + Date d = getWidget().getDate(); + if (d == null) { + // date currently null, use the value from + // calendarPanel + // (~ client time at the init of the widget) + d = (Date) getWidget().calendar.getDate() + .clone(); + } + d.setHours(hour); + d.setMinutes(min); + d.setSeconds(sec); + DateTimeService.setMilliseconds(d, msec); + + // Always update time changes to the server + getWidget().updateValue(d); + + // Update text field + getWidget().buildDate(); + } + }); + } + + if (getWidget().isReadonly()) { + getWidget().calendarToggle.addStyleName( + VPopupCalendar.CLASSNAME + "-button-readonly"); + } else { + getWidget().calendarToggle.removeStyleName( + VPopupCalendar.CLASSNAME + "-button-readonly"); + } + + getWidget().setDescriptionForAssistiveDevices( + getState().descriptionForAssistiveDevices); + + getWidget().setTextFieldTabIndex(); + } + + @Override + public VPopupCalendar getWidget() { + return (VPopupCalendar) super.getWidget(); + } + + @Override + public PopupDateFieldState getState() { + return (PopupDateFieldState) super.getState(); + } + + @Override + public void onStateChanged(StateChangeEvent stateChangeEvent) { + super.onStateChanged(stateChangeEvent); + getWidget().setTextFieldEnabled(getState().textFieldEnabled); + getWidget().setRangeStart(nullSafeDateClone(getState().rangeStart)); + getWidget().setRangeEnd(nullSafeDateClone(getState().rangeEnd)); + } + + private Date nullSafeDateClone(Date date) { + if (date == null) { + return null; + } else { + return (Date) date.clone(); + } + } + + @Override + protected void setWidgetStyleName(String styleName, boolean add) { + super.setWidgetStyleName(styleName, add); + + // update the style change to popup calendar widget + getWidget().popup.setStyleName(styleName, add); + } + + @Override + protected void setWidgetStyleNameWithPrefix(String prefix, String styleName, + boolean add) { + super.setWidgetStyleNameWithPrefix(prefix, styleName, add); + + // update the style change to popup calendar widget with the correct + // prefix + if (!styleName.startsWith("-")) { + getWidget().popup.setStyleName( + getWidget().getStylePrimaryName() + "-popup-" + styleName, + add); + } else { + getWidget().popup.setStyleName( + getWidget().getStylePrimaryName() + "-popup" + styleName, + add); + } + } + +} diff --git a/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/InlineDateFieldConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/InlineDateFieldConnector.java new file mode 100644 index 0000000000..fed8730e48 --- /dev/null +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/InlineDateFieldConnector.java @@ -0,0 +1,131 @@ +/* + * Copyright 2000-2016 Vaadin Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not + * use this file except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ +package com.vaadin.v7.client.ui.datefield; + +import java.util.Date; + +import com.vaadin.client.ApplicationConnection; +import com.vaadin.client.DateTimeService; +import com.vaadin.client.UIDL; +import com.vaadin.client.communication.StateChangeEvent; +import com.vaadin.client.ui.VCalendarPanel.FocusChangeListener; +import com.vaadin.client.ui.VCalendarPanel.TimeChangeListener; +import com.vaadin.client.ui.VDateFieldCalendar; +import com.vaadin.shared.ui.Connect; +import com.vaadin.shared.ui.datefield.InlineDateFieldState; +import com.vaadin.shared.ui.datefield.Resolution; +import com.vaadin.v7.ui.InlineDateField; + +@Connect(InlineDateField.class) +public class InlineDateFieldConnector extends AbstractDateFieldConnector { + + @Override + @SuppressWarnings("deprecation") + public void updateFromUIDL(UIDL uidl, ApplicationConnection client) { + super.updateFromUIDL(uidl, client); + if (!isRealUpdate(uidl)) { + return; + } + + getWidget().calendarPanel + .setShowISOWeekNumbers(getWidget().isShowISOWeekNumbers()); + getWidget().calendarPanel + .setDateTimeService(getWidget().getDateTimeService()); + getWidget().calendarPanel + .setResolution(getWidget().getCurrentResolution()); + Date currentDate = getWidget().getCurrentDate(); + if (currentDate != null) { + getWidget().calendarPanel.setDate(new Date(currentDate.getTime())); + } else { + getWidget().calendarPanel.setDate(null); + } + + if (getWidget().getCurrentResolution() + .getCalendarField() > Resolution.DAY.getCalendarField()) { + getWidget().calendarPanel + .setTimeChangeListener(new TimeChangeListener() { + @Override + public void changed(int hour, int min, int sec, + int msec) { + Date d = getWidget().getDate(); + if (d == null) { + // date currently null, use the value from + // calendarPanel + // (~ client time at the init of the widget) + d = (Date) getWidget().calendarPanel.getDate() + .clone(); + } + d.setHours(hour); + d.setMinutes(min); + d.setSeconds(sec); + DateTimeService.setMilliseconds(d, msec); + + // Always update time changes to the server + getWidget().calendarPanel.setDate(d); + getWidget().updateValueFromPanel(); + } + }); + } + + if (getWidget().getCurrentResolution() + .getCalendarField() <= Resolution.MONTH.getCalendarField()) { + getWidget().calendarPanel + .setFocusChangeListener(new FocusChangeListener() { + @Override + public void focusChanged(Date date) { + Date date2 = new Date(); + if (getWidget().calendarPanel.getDate() != null) { + date2.setTime(getWidget().calendarPanel + .getDate().getTime()); + } + /* + * Update the value of calendarPanel + */ + date2.setYear(date.getYear()); + date2.setMonth(date.getMonth()); + getWidget().calendarPanel.setDate(date2); + /* + * Then update the value from panel to server + */ + getWidget().updateValueFromPanel(); + } + }); + } else { + getWidget().calendarPanel.setFocusChangeListener(null); + } + + // Update possible changes + getWidget().calendarPanel.renderCalendar(); + } + + @Override + public void onStateChanged(StateChangeEvent stateChangeEvent) { + super.onStateChanged(stateChangeEvent); + getWidget().setTabIndex(getState().tabIndex); + getWidget().calendarPanel.setRangeStart(getState().rangeStart); + getWidget().calendarPanel.setRangeEnd(getState().rangeEnd); + } + + @Override + public VDateFieldCalendar getWidget() { + return (VDateFieldCalendar) super.getWidget(); + } + + @Override + public InlineDateFieldState getState() { + return (InlineDateFieldState) super.getState(); + } +} diff --git a/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyPopupDateFieldConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/PopupDateFieldConnector.java index 15311ade5f..2eac74803d 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/v7/ui/LegacyPopupDateFieldConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/PopupDateFieldConnector.java @@ -13,18 +13,13 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.v7.ui; -import com.vaadin.client.ui.datefield.PopupDateFieldConnector; +package com.vaadin.v7.client.ui.datefield; + import com.vaadin.shared.ui.Connect; import com.vaadin.v7.ui.PopupDateField; -/** - * @author Vaadin Ltd - * - */ -@Deprecated @Connect(PopupDateField.class) -public class LegacyPopupDateFieldConnector extends PopupDateFieldConnector { +public class PopupDateFieldConnector extends DateFieldConnector { } diff --git a/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/TextualDateConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/TextualDateConnector.java new file mode 100644 index 0000000000..6eb5f900ea --- /dev/null +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/datefield/TextualDateConnector.java @@ -0,0 +1,67 @@ +/* + * Copyright 2000-2016 Vaadin Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not + * use this file except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ + +package com.vaadin.v7.client.ui.datefield; + +import com.vaadin.client.ApplicationConnection; +import com.vaadin.client.UIDL; +import com.vaadin.client.ui.VTextualDate; +import com.vaadin.shared.ui.datefield.Resolution; +import com.vaadin.shared.ui.datefield.TextualDateFieldState; + +public class TextualDateConnector extends AbstractDateFieldConnector { + + @Override + public void updateFromUIDL(UIDL uidl, ApplicationConnection client) { + Resolution origRes = getWidget().getCurrentResolution(); + String oldLocale = getWidget().getCurrentLocale(); + super.updateFromUIDL(uidl, client); + if (origRes != getWidget().getCurrentResolution() + || oldLocale != getWidget().getCurrentLocale()) { + // force recreating format string + getWidget().formatStr = null; + } + if (uidl.hasAttribute("format")) { + getWidget().formatStr = uidl.getStringAttribute("format"); + } + + getWidget().inputPrompt = uidl + .getStringAttribute(VTextualDate.ATTR_INPUTPROMPT); + + getWidget().lenient = !uidl.getBooleanAttribute("strict"); + + getWidget().buildDate(); + // not a FocusWidget -> needs own tabindex handling + getWidget().text.setTabIndex(getState().tabIndex); + + if (getWidget().isReadonly()) { + getWidget().text.addStyleDependentName("readonly"); + } else { + getWidget().text.removeStyleDependentName("readonly"); + } + + } + + @Override + public VTextualDate getWidget() { + return (VTextualDate) super.getWidget(); + } + + @Override + public TextualDateFieldState getState() { + return (TextualDateFieldState) super.getState(); + } +} diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/dd/VIsOverId.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/dd/VIsOverId.java index cd4bf13ba0..55a319c5ad 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/dd/VIsOverId.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/dd/VIsOverId.java @@ -16,10 +16,14 @@ /** * */ -package com.vaadin.client.ui.dd; +package com.vaadin.v7.client.ui.dd; import com.vaadin.client.ComponentConnector; import com.vaadin.client.UIDL; +import com.vaadin.client.ui.dd.VAcceptCriterion; +import com.vaadin.client.ui.dd.VDragAndDropManager; +import com.vaadin.client.ui.dd.VDragEvent; +import com.vaadin.client.ui.dd.VDropHandler; import com.vaadin.shared.ui.dd.AcceptCriterion; import com.vaadin.v7.ui.AbstractSelect; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/dd/VItemIdIs.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/dd/VItemIdIs.java index f8bfe075a3..0cecb5b9b1 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/dd/VItemIdIs.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/dd/VItemIdIs.java @@ -16,10 +16,12 @@ /** * */ -package com.vaadin.client.ui.dd; +package com.vaadin.v7.client.ui.dd; import com.vaadin.client.ComponentConnector; import com.vaadin.client.UIDL; +import com.vaadin.client.ui.dd.VAcceptCriterion; +import com.vaadin.client.ui.dd.VDragEvent; import com.vaadin.shared.ui.dd.AcceptCriterion; import com.vaadin.v7.ui.AbstractSelect; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/listselect/ListSelectConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/listselect/ListSelectConnector.java index e288c088a9..5f515f5570 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/listselect/ListSelectConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/listselect/ListSelectConnector.java @@ -14,11 +14,11 @@ * the License. */ -package com.vaadin.client.ui.listselect; +package com.vaadin.v7.client.ui.listselect; import com.vaadin.client.ui.VListSelect; -import com.vaadin.client.ui.optiongroup.OptionGroupBaseConnector; import com.vaadin.shared.ui.Connect; +import com.vaadin.v7.client.ui.optiongroup.OptionGroupBaseConnector; import com.vaadin.v7.ui.ListSelect; @Connect(ListSelect.class) diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/nativeselect/NativeSelectConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/nativeselect/NativeSelectConnector.java index 0063116cdb..49bdce4baf 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/nativeselect/NativeSelectConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/nativeselect/NativeSelectConnector.java @@ -14,12 +14,12 @@ * the License. */ -package com.vaadin.client.ui.nativeselect; +package com.vaadin.v7.client.ui.nativeselect; import com.vaadin.client.ui.ConnectorFocusAndBlurHandler; import com.vaadin.client.ui.VNativeSelect; -import com.vaadin.client.ui.optiongroup.OptionGroupBaseConnector; import com.vaadin.shared.ui.Connect; +import com.vaadin.v7.client.ui.optiongroup.OptionGroupBaseConnector; import com.vaadin.v7.ui.NativeSelect; @Connect(NativeSelect.class) diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/optiongroup/OptionGroupBaseConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/optiongroup/OptionGroupBaseConnector.java index 24454c833d..6a89498c7c 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/optiongroup/OptionGroupBaseConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/optiongroup/OptionGroupBaseConnector.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui.optiongroup; +package com.vaadin.v7.client.ui.optiongroup; import com.vaadin.client.ApplicationConnection; import com.vaadin.client.Paintable; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/optiongroup/OptionGroupConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/optiongroup/OptionGroupConnector.java index e8164632b4..d648115447 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/optiongroup/OptionGroupConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/optiongroup/OptionGroupConnector.java @@ -14,7 +14,7 @@ * the License. */ -package com.vaadin.client.ui.optiongroup; +package com.vaadin.v7.client.ui.optiongroup; import java.util.ArrayList; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/richtextarea/RichTextAreaConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/richtextarea/RichTextAreaConnector.java index 2ea59046c7..a24ac6b7db 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/richtextarea/RichTextAreaConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/richtextarea/RichTextAreaConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.richtextarea; +package com.vaadin.v7.client.ui.richtextarea; import com.google.gwt.event.dom.client.BlurEvent; import com.google.gwt.event.dom.client.BlurHandler; @@ -22,11 +22,11 @@ import com.vaadin.client.Paintable; import com.vaadin.client.UIDL; import com.vaadin.client.ui.AbstractFieldConnector; import com.vaadin.client.ui.SimpleManagedLayout; -import com.vaadin.client.ui.VRichTextArea; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.Connect.LoadStyle; import com.vaadin.shared.ui.textarea.RichTextAreaState; import com.vaadin.shared.util.SharedUtil; +import com.vaadin.v7.client.ui.VRichTextArea; import com.vaadin.v7.ui.RichTextArea; @Connect(value = RichTextArea.class, loadStyle = LoadStyle.LAZY) diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/richtextarea/VRichTextToolbar.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/richtextarea/VRichTextToolbar.java index 10c1de75e6..fcb189dfd7 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/richtextarea/VRichTextToolbar.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/richtextarea/VRichTextToolbar.java @@ -28,7 +28,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.richtextarea; +package com.vaadin.v7.client.ui.richtextarea; import com.google.gwt.core.client.GWT; import com.google.gwt.event.dom.client.ChangeEvent; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/table/TableConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/table/TableConnector.java index 8bd2418aea..69395cd8ba 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/table/TableConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/table/TableConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.table; +package com.vaadin.v7.client.ui.table; import java.util.Collections; import java.util.Iterator; @@ -39,15 +39,15 @@ import com.vaadin.client.UIDL; import com.vaadin.client.WidgetUtil; import com.vaadin.client.ui.AbstractFieldConnector; import com.vaadin.client.ui.PostLayoutListener; -import com.vaadin.client.ui.VScrollTable; -import com.vaadin.client.ui.VScrollTable.ContextMenuDetails; -import com.vaadin.client.ui.VScrollTable.FooterCell; -import com.vaadin.client.ui.VScrollTable.HeaderCell; -import com.vaadin.client.ui.VScrollTable.VScrollTableBody.VScrollTableRow; import com.vaadin.shared.MouseEventDetails; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.table.TableConstants; import com.vaadin.shared.ui.table.TableConstants.Section; +import com.vaadin.v7.client.ui.VScrollTable; +import com.vaadin.v7.client.ui.VScrollTable.ContextMenuDetails; +import com.vaadin.v7.client.ui.VScrollTable.FooterCell; +import com.vaadin.v7.client.ui.VScrollTable.HeaderCell; +import com.vaadin.v7.client.ui.VScrollTable.VScrollTableBody.VScrollTableRow; import com.vaadin.shared.ui.table.TableServerRpc; import com.vaadin.shared.ui.table.TableState; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/table/VTableLazyInitItemIdentifiers.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/table/VTableLazyInitItemIdentifiers.java index c3b2185de8..419a5f1e6a 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/table/VTableLazyInitItemIdentifiers.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/table/VTableLazyInitItemIdentifiers.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.table; +package com.vaadin.v7.client.ui.table; import com.vaadin.client.ui.dd.VLazyInitItemIdentifiers; import com.vaadin.shared.ui.dd.AcceptCriterion; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/textarea/TextAreaConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/textarea/TextAreaConnector.java index 75b6ba21ee..81c9949af9 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/textarea/TextAreaConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/textarea/TextAreaConnector.java @@ -14,16 +14,16 @@ * the License. */ -package com.vaadin.client.ui.textarea; +package com.vaadin.v7.client.ui.textarea; import com.google.gwt.dom.client.Element; import com.google.gwt.event.dom.client.MouseUpEvent; import com.google.gwt.event.dom.client.MouseUpHandler; import com.vaadin.client.WidgetUtil.CssSize; -import com.vaadin.client.ui.VTextArea; import com.vaadin.client.v7.ui.textfield.LegacyTextFieldConnector; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.textarea.TextAreaState; +import com.vaadin.v7.client.ui.VTextArea; import com.vaadin.v7.ui.TextArea; @Connect(TextArea.class) diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/tree/TreeConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/tree/TreeConnector.java index 173048ec1e..c9b58da9fc 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/tree/TreeConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/tree/TreeConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.tree; +package com.vaadin.v7.client.ui.tree; import java.util.HashMap; import java.util.Iterator; @@ -32,14 +32,14 @@ import com.vaadin.client.VConsole; import com.vaadin.client.WidgetUtil; import com.vaadin.client.communication.StateChangeEvent; import com.vaadin.client.ui.AbstractComponentConnector; -import com.vaadin.client.ui.VTree; -import com.vaadin.client.ui.VTree.TreeNode; import com.vaadin.shared.MouseEventDetails; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.MultiSelectMode; import com.vaadin.shared.ui.tree.TreeConstants; import com.vaadin.shared.ui.tree.TreeServerRpc; import com.vaadin.shared.ui.tree.TreeState; +import com.vaadin.v7.client.ui.VTree; +import com.vaadin.v7.client.ui.VTree.TreeNode; import com.vaadin.v7.ui.Tree; @Connect(Tree.class) diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/tree/VTargetInSubtree.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/tree/VTargetInSubtree.java index 8f38a8cfb4..9cc80c0e17 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/tree/VTargetInSubtree.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/tree/VTargetInSubtree.java @@ -16,16 +16,16 @@ /** * */ -package com.vaadin.client.ui.tree; +package com.vaadin.v7.client.ui.tree; import com.google.gwt.user.client.ui.Widget; import com.vaadin.client.UIDL; -import com.vaadin.client.ui.VTree; -import com.vaadin.client.ui.VTree.TreeNode; import com.vaadin.client.ui.dd.VAcceptCriterion; import com.vaadin.client.ui.dd.VDragAndDropManager; import com.vaadin.client.ui.dd.VDragEvent; import com.vaadin.shared.ui.dd.AcceptCriterion; +import com.vaadin.v7.client.ui.VTree; +import com.vaadin.v7.client.ui.VTree.TreeNode; import com.vaadin.v7.ui.Tree; @AcceptCriterion(Tree.TargetInSubtree.class) diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/tree/VTreeLazyInitItemIdentifiers.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/tree/VTreeLazyInitItemIdentifiers.java index e4ba64e12a..0a3c779ec9 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/tree/VTreeLazyInitItemIdentifiers.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/tree/VTreeLazyInitItemIdentifiers.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.tree; +package com.vaadin.v7.client.ui.tree; import com.vaadin.client.ui.dd.VLazyInitItemIdentifiers; import com.vaadin.shared.ui.dd.AcceptCriterion; diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/treetable/TreeTableConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/treetable/TreeTableConnector.java index 7c1cac61c6..5fbdafe1b7 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/treetable/TreeTableConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/treetable/TreeTableConnector.java @@ -13,7 +13,7 @@ * License for the specific language governing permissions and limitations under * the License. */ -package com.vaadin.client.ui.treetable; +package com.vaadin.v7.client.ui.treetable; import com.google.gwt.dom.client.Element; import com.vaadin.client.ApplicationConnection; @@ -21,14 +21,14 @@ import com.vaadin.client.TooltipInfo; import com.vaadin.client.UIDL; import com.vaadin.client.WidgetUtil; import com.vaadin.client.ui.FocusableScrollPanel; -import com.vaadin.client.ui.VScrollTable.VScrollTableBody.VScrollTableRow; -import com.vaadin.client.ui.VTreeTable; -import com.vaadin.client.ui.VTreeTable.PendingNavigationEvent; -import com.vaadin.client.ui.VTreeTable.VTreeTableScrollBody.VTreeTableRow; -import com.vaadin.client.ui.table.TableConnector; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.treetable.TreeTableConstants; import com.vaadin.shared.ui.treetable.TreeTableState; +import com.vaadin.v7.client.ui.VTreeTable; +import com.vaadin.v7.client.ui.VScrollTable.VScrollTableBody.VScrollTableRow; +import com.vaadin.v7.client.ui.VTreeTable.PendingNavigationEvent; +import com.vaadin.v7.client.ui.VTreeTable.VTreeTableScrollBody.VTreeTableRow; +import com.vaadin.v7.client.ui.table.TableConnector; import com.vaadin.v7.ui.TreeTable; @Connect(TreeTable.class) diff --git a/compatibility-client/src/main/java/com/vaadin/client/ui/twincolselect/TwinColSelectConnector.java b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/twincolselect/TwinColSelectConnector.java index 5e05dae166..218792fc89 100644 --- a/compatibility-client/src/main/java/com/vaadin/client/ui/twincolselect/TwinColSelectConnector.java +++ b/compatibility-client/src/main/java/com/vaadin/v7/client/ui/twincolselect/TwinColSelectConnector.java @@ -14,15 +14,15 @@ * the License. */ -package com.vaadin.client.ui.twincolselect; +package com.vaadin.v7.client.ui.twincolselect; import com.vaadin.client.ApplicationConnection; import com.vaadin.client.DirectionalManagedLayout; import com.vaadin.client.UIDL; import com.vaadin.client.ui.VTwinColSelect; -import com.vaadin.client.ui.optiongroup.OptionGroupBaseConnector; import com.vaadin.shared.ui.Connect; import com.vaadin.shared.ui.twincolselect.TwinColSelectState; +import com.vaadin.v7.client.ui.optiongroup.OptionGroupBaseConnector; import com.vaadin.v7.ui.TwinColSelect; @Connect(TwinColSelect.class) diff --git a/compatibility-client/src/main/resources/com/vaadin/Vaadin7WidgetSet.gwt.xml b/compatibility-client/src/main/resources/com/vaadin/v7/Vaadin7WidgetSet.gwt.xml index e124491d3a..e124491d3a 100755 --- a/compatibility-client/src/main/resources/com/vaadin/Vaadin7WidgetSet.gwt.xml +++ b/compatibility-client/src/main/resources/com/vaadin/v7/Vaadin7WidgetSet.gwt.xml diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/VRichTextToolbar$Strings.properties b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/VRichTextToolbar$Strings.properties new file mode 100644 index 0000000000..363b704584 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/VRichTextToolbar$Strings.properties @@ -0,0 +1,35 @@ +bold = Toggle Bold +createLink = Create Link +hr = Insert Horizontal Rule +indent = Indent Right +insertImage = Insert Image +italic = Toggle Italic +justifyCenter = Center +justifyLeft = Left Justify +justifyRight = Right Justify +ol = Insert Ordered List +outdent = Indent Left +removeFormat = Remove Formatting +removeLink = Remove Link +strikeThrough = Toggle Strikethrough +subscript = Toggle Subscript +superscript = Toggle Superscript +ul = Insert Unordered List +underline = Toggle Underline +color = Color +black = Black +white = White +red = Red +green = Green +yellow = Yellow +blue = Blue +font = Font +normal = Normal +size = Size +xxsmall = XX-Small +xsmall = X-Small +small = Small +medium = Medium +large = Large +xlarge = X-Large +xxlarge = XX-Large
\ No newline at end of file diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/backColors.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/backColors.gif Binary files differnew file mode 100644 index 0000000000..ddfc1cea2c --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/backColors.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/bold.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/bold.gif Binary files differnew file mode 100644 index 0000000000..7c22eaac68 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/bold.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/createLink.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/createLink.gif Binary files differnew file mode 100644 index 0000000000..1a1412fe0e --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/createLink.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/fontSizes.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/fontSizes.gif Binary files differnew file mode 100644 index 0000000000..c2f4c8cb21 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/fontSizes.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/fonts.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/fonts.gif Binary files differnew file mode 100644 index 0000000000..1629cabb78 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/fonts.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/foreColors.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/foreColors.gif Binary files differnew file mode 100644 index 0000000000..2bb89ef189 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/foreColors.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/gwtLogo.png b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/gwtLogo.png Binary files differnew file mode 100644 index 0000000000..80728186d8 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/gwtLogo.png diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/hr.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/hr.gif Binary files differnew file mode 100644 index 0000000000..d507082cf1 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/hr.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/indent.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/indent.gif Binary files differnew file mode 100644 index 0000000000..905421ed76 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/indent.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/insertImage.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/insertImage.gif Binary files differnew file mode 100644 index 0000000000..394ec432a5 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/insertImage.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/italic.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/italic.gif Binary files differnew file mode 100644 index 0000000000..ffe0e97284 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/italic.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyCenter.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyCenter.gif Binary files differnew file mode 100644 index 0000000000..f7d4c4693d --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyCenter.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyLeft.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyLeft.gif Binary files differnew file mode 100644 index 0000000000..bc37a3ed5a --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyLeft.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyRight.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyRight.gif Binary files differnew file mode 100644 index 0000000000..892d569384 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/justifyRight.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/ol.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/ol.gif Binary files differnew file mode 100644 index 0000000000..54f8e4f551 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/ol.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/outdent.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/outdent.gif Binary files differnew file mode 100644 index 0000000000..78fd1b5722 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/outdent.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/removeFormat.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/removeFormat.gif Binary files differnew file mode 100644 index 0000000000..cf92c9774f --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/removeFormat.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/removeLink.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/removeLink.gif Binary files differnew file mode 100644 index 0000000000..40721a7bca --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/removeLink.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/strikeThrough.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/strikeThrough.gif Binary files differnew file mode 100644 index 0000000000..a7a233c023 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/strikeThrough.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/subscript.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/subscript.gif Binary files differnew file mode 100644 index 0000000000..58b6fbb816 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/subscript.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/superscript.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/superscript.gif Binary files differnew file mode 100644 index 0000000000..a6270f6e21 --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/superscript.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/ul.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/ul.gif Binary files differnew file mode 100644 index 0000000000..83f1562bcb --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/ul.gif diff --git a/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/underline.gif b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/underline.gif Binary files differnew file mode 100644 index 0000000000..06f0200fdd --- /dev/null +++ b/compatibility-client/src/main/resources/com/vaadin/v7/client/ui/richtextarea/underline.gif |