That particular sample happened to have few enough records that the whole dataset could be rendered at once, so you wouldn't see the open space at the end, so the virtualScrolling:false setting has no visible effect until there are more records.
But yes, if you are going to disable virtual scrolling with recordComponents, you do need to set recordComponentHeight, and you need to ensure you aren't using any other features that would normally turn on virtual scrolling (as listed in the docs).
Announcement
Collapse
No announcement yet.
X
-
Hi Isomorphic,
I tested the default behavior a bit: In the sample (now on v11.0p_2017-05-07),
Code:virtualScrolling:false
Code:recordComponentHeight: 22
Without it, virtualScrolling it always enabled.
This is in sync with the docs.
I assume that for a use case like in the sample you suggest setting
Code:virtualScrolling:false, recordComponentHeight: 22 // (where 22 is the max height of the possible recordComponents)
Best regards
Blama
Leave a comment:
-
There is a slight clarity advantage to setting recordComponentHeight instead of virtualScrolling:false, since setting virtualScrolling:false would disable virtual scrolling even if it is needed for a purpose *other than* record components.
Leave a comment:
-
Hi Isomorphic,
Originally posted by Isomorphic View PostIf you have fixed height recordComponents - yes we'd recommend you setRecordComponentHeight() so the grid knows how tall rows will render.
I assume virtualScrolling: false, but I'm not sure.
Best regards
Blama
Leave a comment:
-
Hi Isomorphic,
it's now working in all browsers (tested Win8.1 with IE11 FF26 GC44) with v10.0p_2015-08-18/PowerEdition Deployment.
Thank you & Best regards
Blama
Leave a comment:
-
We've ported additional files for SGWT 5.0p (it should be working for SGWT 5.1d as is). This should be in the nightly builds for 2015-08-18.
Leave a comment:
-
Hi Isomorphic,
I retested with the same test case as before (using Simplicity and java code from #21) and v10.0p_2015-08-16/PowerEdition Deployment.
The result for IE11/Win8.1 did not change. The same bugs are still present ("Scrollbar-knob resizes to minimal size", "Scrollbar-knob is completely gone, as are the up/down arrows at the end of the scrollbar").
Actually, also for FF26 and GC44 the "Scrollbar-knob resizes to minimal size" is present to when doing fast scrollknob-dragging to the very bottom of the scrollbar.
Best regards
Blama
Leave a comment:
-
We're making a fix for the IE11 issues in SGWT 5.0p and newer that will be in the builds marked 2015-08-11.
Leave a comment:
-
Hi Isomorphic,
yes, only IE11 (I did not test other IE versions).
Best regards
Blama
Leave a comment:
-
Originally posted by Blama View Post
The fix helps me very much, but you might want to look into this nevertheless.
Best regards
Blama
Leave a comment:
-
Hi Isomorphic,
I retested with 5.0p v10.0p_2015-08-06/PowerEdition Deployment (I did not test 5.1d, yet).
It seems to work in GC44, FF26 (using virtual scrolling, but the "jumping"-bug is gone and if scrolled down totally, the last record is still fully visible, so the "fully empty page"-bug is gone as well).
This is also true for IE11, but here there is another (new) problem, when scrolling down totally:- I used the same testcase ("Christian Jeansonne" as last visible entry for me)
- Select 1st record
- Hit "Page down"-button 4x ("Whitney Rogers" as last visible entry for me at the very bottom)
- Hit "Page down"-button one more time.
- "Whitney Rogers" only visible entry on the very top. Scrollbar-knob resizes to minimal size.
Alternative: If I scroll to the very bottom with scrollknob-dragging, the Scrollbar-knob is completely gone, as are the up/down arrows at the end of the scrollbar (see screenshot).
The fix helps me very much, but you might want to look into this nevertheless.
Best regards
Blama
Leave a comment:
-
Hi Isomorphic,
thanks, I'll test with the testcase and in my app and let you know.
Does this fix the "jumping"-bug and the "fully empty page"-bug?
Or does it circumvent those bugs by not using virtual scrolling because virtual scrolling is not necessary when using setRecordComponentHeight()+ListGrid.showRecordComponents(true)?
Best regards
Blama
Leave a comment:
-
We've made an adjustment to the logic that detects virtual scrolling which should fix the issues you've encountered. The fix will be in SGWT 5.0p and newer in the nightlies dated 08-06-2015.
Leave a comment:
-
Hi Isomorphic,
please see this revised testcase, which makes testing a bit more easy.
BuiltInDS.java
Code:package com.smartgwt.sample.client; import com.google.gwt.core.client.EntryPoint; import com.smartgwt.client.core.KeyIdentifier; import com.smartgwt.client.data.AdvancedCriteria; import com.smartgwt.client.data.Criterion; import com.smartgwt.client.data.DSCallback; import com.smartgwt.client.data.DSRequest; import com.smartgwt.client.data.DSResponse; import com.smartgwt.client.data.DataSource; import com.smartgwt.client.types.AutoFitWidthApproach; import com.smartgwt.client.types.GroupStartOpen; import com.smartgwt.client.types.OperatorId; import com.smartgwt.client.types.RecordComponentPoolingMode; import com.smartgwt.client.util.PageKeyHandler; import com.smartgwt.client.util.Page; import com.smartgwt.client.util.SC; import com.smartgwt.client.widgets.IButton; import com.smartgwt.client.widgets.events.ClickEvent; import com.smartgwt.client.widgets.events.ClickHandler; import com.smartgwt.client.widgets.form.DynamicForm; import com.smartgwt.client.widgets.form.fields.BooleanItem; import com.smartgwt.client.widgets.form.fields.TextItem; import com.smartgwt.client.widgets.grid.ListGrid; import com.smartgwt.client.widgets.layout.HLayout; import com.smartgwt.client.widgets.layout.VLayout; public class BuiltInDS implements EntryPoint { private VLayout vL; private TestGrid tG; private HLayout hL; DynamicForm dF; public void onModuleLoad() { setListGridDefaultApperance(); KeyIdentifier debugKey = new KeyIdentifier(); debugKey.setCtrlKey(true); debugKey.setKeyName("D"); Page.registerKey(debugKey, new PageKeyHandler() { public void execute(String keyName) { SC.showConsole(); } }); vL = new VLayout(5); vL.setPadding(20); vL.setWidth100(); vL.setHeight100(); tG = new TestGrid("A", false); hL = new HLayout(5); hL.setHeight(40); dF = new DynamicForm(); dF.setNumCols(4); TextItem startLetter = new TextItem("startLetter", "Start letter"); BooleanItem groupBy = new BooleanItem("groupBy", "Group by gender"); dF.setFields(startLetter, groupBy); IButton reloadBtn = new IButton("Reload ?-Z"); reloadBtn.setWidth(150); reloadBtn.addClickHandler(new ClickHandler() { @Override public void onClick(ClickEvent event) { vL.removeChild(tG); tG.markForDestroy(); Object startLetterObj = dF.getValue("startLetter"); Object groupByObj = dF.getValue("groupBy"); boolean groupBy = false; if (groupByObj != null) groupBy = (Boolean) groupByObj; if (startLetterObj != null) tG = new TestGrid(startLetterObj.toString(), groupBy); else tG = new TestGrid("A", groupBy); vL.addMember(tG, 0); } }); hL.addMembers(dF, reloadBtn); vL.addMembers(tG, hL); vL.draw(); } private class TestGrid extends ListGrid { public TestGrid(String greaterThan, boolean groupBy) { super(); setShowFilterEditor(true); setDataSource(DataSource.get("employees")); setAutoFetchData(false); setAutoFetchData(false); setShowFilterEditor(false); setShowRecordComponents(true); setShowRecordComponentsByCell(true); setRecordComponentPoolingMode(RecordComponentPoolingMode.RECYCLE); setPoolComponentsPerColumn(true); setRecordComponentHeight(22); setCanGroupBy(false); setCanReorderFields(true); setGroupStartOpen(GroupStartOpen.ALL); setSortByGroupFirst(true); setSortField("Name"); if (groupBy) setGroupByField("Gender"); fetchData(new AdvancedCriteria(new Criterion("Name", OperatorId.GREATER_OR_EQUAL, greaterThan)), new DSCallback() { @Override public void execute(DSResponse dsResponse, Object data, DSRequest dsRequest) { SC.say("Using VirtualScrolling: '" + getVirtualScrolling() + "'"); } }); } } private static void setListGridDefaultApperance() { ListGrid lg = new ListGrid() { { setAutoFitFieldsFillViewport(true); setShowClippedValuesOnHover(true); setAutoFitWidthApproach(AutoFitWidthApproach.VALUE); setCanGroupBy(true); setCanMultiGroup(false); setCanEdit(false); setShowFilterEditor(false); setCanFreezeFields(false); setCanReorderFields(false); setCellHeight(30); setHeaderHeight(35); setFixedRecordHeights(true); setGroupIconSize(30); setGroupLeadingIndent(0); setHoverDelay(500); } }; ListGrid.setDefaultProperties(lg); } }
Originally posted by Isomorphic View PostYou should not be able to scroll the last row completely out of view, though. When scrolled to the bottom extrema, the last row should still be visible at the top.
Originally posted by Blama View PostIs this still true when I use ListGrid.setRecordComponentHeight()? The size should be known then, shouldn't it?
Or the other way around: Is it somehow possible not to have VirtualScrolling when using showRecordComponents(true)?- Using SNAPSHOT_v10.1d_2015-07-29 I do have the "total empty page"-problem on startup.
- Using SNAPSHOT_v10.1d_2015-07-29 I do not have the "total empty page"-problem and "jumping"-problem when reloading "L-Z". The Popup still says "VirtualScrolling: true", though.
I do have the problem with more entries (e.g. "K-Z"). Note: On start with my browser (1920x1080 minus browser UI) I can see "Christian Jeansonne" as last visible entry. - When I resize the browser window to make it smaller in height, I get the "jumping"-problem as well as the "total empty page"-problem also when reloading "L-Z" (therefore perhaps drawAheadRatio related?).
- This is true for v10.0p_2015-07-30 as well. No difference between 5.0p and 5.1d at all. Actually also the "jumping" happens with v10.0p_2015-07-30. I did not report that before.
As sidenote: I do have the ListGrid grouped in my application, but this does not seem to matter here.
Best regards
BlamaLast edited by Blama; 31 Jul 2015, 02:20.
Leave a comment:
Leave a comment: