diff options
author | Anthony Guerreiro <anthony@vaadin.com> | 2014-07-29 13:11:51 +0100 |
---|---|---|
committer | Anthony Guerreiro <anthony@vaadin.com> | 2014-07-29 13:11:51 +0100 |
commit | 392e8a032f24abfac038dbb924e14420c514cf0a (patch) | |
tree | c803d85274bec9fdced0a155b736786f8a5c2f06 /client | |
parent | 8d470c9802ee33d6dfaf26adad7b2269b665bf44 (diff) | |
download | vaadin-framework-392e8a032f24abfac038dbb924e14420c514cf0a.tar.gz vaadin-framework-392e8a032f24abfac038dbb924e14420c514cf0a.zip |
Minor refactor to #14147 patch (#14147)
Change-Id: I78cdbbad41fa6980f445ae770f7e7a8d7db39176
Diffstat (limited to 'client')
-rw-r--r-- | client/src/com/vaadin/client/ui/VScrollTable.java | 2 | ||||
-rw-r--r-- | client/src/com/vaadin/client/ui/table/TableConnector.java | 18 |
2 files changed, 10 insertions, 10 deletions
diff --git a/client/src/com/vaadin/client/ui/VScrollTable.java b/client/src/com/vaadin/client/ui/VScrollTable.java index af469949a8..9c271858e0 100644 --- a/client/src/com/vaadin/client/ui/VScrollTable.java +++ b/client/src/com/vaadin/client/ui/VScrollTable.java @@ -8026,7 +8026,7 @@ public class VScrollTable extends FlowPanel implements HasWidgets, } } - public void totalRowsChanged() { + public void totalRowsHaveChanged() { firstvisibleOnLastPage = -1; } } diff --git a/client/src/com/vaadin/client/ui/table/TableConnector.java b/client/src/com/vaadin/client/ui/table/TableConnector.java index 04a2dfc3c4..d3535e96c9 100644 --- a/client/src/com/vaadin/client/ui/table/TableConnector.java +++ b/client/src/com/vaadin/client/ui/table/TableConnector.java @@ -1,12 +1,12 @@ /* * Copyright 2000-2014 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 @@ -64,7 +64,7 @@ public class TableConnector extends AbstractHasComponentsConnector implements /* * (non-Javadoc) - * + * * @see com.vaadin.client.Paintable#updateFromUIDL(com.vaadin.client.UIDL, * com.vaadin.client.ApplicationConnection) */ @@ -121,7 +121,7 @@ public class TableConnector extends AbstractHasComponentsConnector implements int previousTotalRows = getWidget().totalRows; getWidget().updateTotalRows(uidl); - boolean totalRowsChanged = (getWidget().totalRows != previousTotalRows); + boolean totalRowsHaveChanged = (getWidget().totalRows != previousTotalRows); getWidget().updateDragMode(uidl); @@ -146,8 +146,8 @@ public class TableConnector extends AbstractHasComponentsConnector implements getWidget().updatePageLength(uidl); getWidget().updateFirstVisibleAndScrollIfNeeded(uidl); - if (totalRowsChanged == true) { - getWidget().totalRowsChanged(); + if (totalRowsHaveChanged) { + getWidget().totalRowsHaveChanged(); } getWidget().showRowHeaders = uidl.getBooleanAttribute("rowheaders"); @@ -202,7 +202,7 @@ public class TableConnector extends AbstractHasComponentsConnector implements if (getWidget().headerChangedDuringUpdate) { getWidget().triggerLazyColumnAdjustment(true); } else if (!getWidget().isScrollPositionVisible() - || totalRowsChanged + || totalRowsHaveChanged || getWidget().lastRenderedHeight != getWidget().scrollBody .getOffsetHeight()) { // webkits may still bug with their disturbing scrollbar @@ -387,7 +387,7 @@ public class TableConnector extends AbstractHasComponentsConnector implements /** * Shows a saved row context menu if the row for the context menu is still * visible. Does nothing if a context menu has not been saved. - * + * * @param savedContextMenu */ public void showSavedContextMenu(ContextMenuDetails savedContextMenu) { |