mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-23 18:17:20 +00:00
Fixes to classic and sideways list views
This commit is contained in:
parent
66087085e7
commit
931bea1194
@ -32,13 +32,13 @@ ClassicListView.prototype.navigateTo = function(historyInfo) {
|
||||
var srcRect = historyInfo.fromPageRect;
|
||||
if(!srcRect) {
|
||||
var scrollPos = $tw.utils.getScrollPosition();
|
||||
srcRect.width = window.innerWidth;
|
||||
srcRect.height = window.innerHeight;
|
||||
srcRect = {
|
||||
left: scrollPos.x,
|
||||
top: scrollPos.y,
|
||||
right: scrollPos.x + srcRect.width,
|
||||
bottom: scrollPos.y + srcRect.height
|
||||
right: scrollPos.x + window.innerWidth,
|
||||
bottom: scrollPos.y + window.innerHeight,
|
||||
width: window.innerWidth,
|
||||
height: window.innerHeight
|
||||
};
|
||||
};
|
||||
var dstRect = $tw.utils.getBoundingPageRect(targetElement);
|
||||
|
@ -25,13 +25,13 @@ SidewaysListView.prototype.navigateTo = function(historyInfo) {
|
||||
var srcRect = historyInfo.fromPageRect;
|
||||
if(!srcRect) {
|
||||
var scrollPos = $tw.utils.getScrollPosition();
|
||||
srcRect.width = window.innerWidth;
|
||||
srcRect.height = window.innerHeight;
|
||||
srcRect = {
|
||||
left: scrollPos.x,
|
||||
top: scrollPos.y,
|
||||
right: scrollPos.x + srcRect.width,
|
||||
bottom: scrollPos.y + srcRect.height
|
||||
right: scrollPos.x + window.innerWidth,
|
||||
bottom: scrollPos.y + window.innerHeight,
|
||||
width: window.innerWidth,
|
||||
height: window.innerHeight
|
||||
};
|
||||
};
|
||||
var dstRect = $tw.utils.getBoundingPageRect(targetElement);
|
||||
|
Loading…
Reference in New Issue
Block a user