Quantcast
Channel: Appcelerator Developer Center Q&A Unanswered Questions 20
Viewing all articles
Browse latest Browse all 8068

ScrollView Jerks to the Left

$
0
0

Image:

![Jerky Scrollview](http://silo.schr.fr/scrollview_error_when_selecting_city.gif "ScrollView Jerks to the Left")

I’ve tried loads of things, but I seem to keep having this problem. There is a ScrollView that is defined to be the width of the screen. There is a modal window that pops up.

Now, on the iPhone 3.5" simulator (and sometimes on the 4" as well), often (not always!), closing the modal window seems to shift the entire page to the left, as if the scrollView is wider than the screen.

I have to drag the scrollview back again. Yet the scrollView is explicitly defined to be the width of the screen, as is the window!

I’ve tried countless variations of properties, to no avail, if anyone can point me in the right direction that would be great!

Cheers,

I’ve defined a scrollView as such:

var settingsScrollView = Ti.UI.createScrollView({ width: Ti.Platform.displayCaps.platformWidth, height: Ti.Platform.displayCaps.platformHeight, contentWidth: Ti.Platform.displayCaps.platformWidth, left: 0, right: 0, bottom: 0, top: 0, layout: 'vertical', showVerticalScrollIndicator: true, showHorizontalScrollIndicator: false });

And a modal window as such:

var citiesWindow = Ti.UI.createWindow({
    modal: true
});

The settingsWindow is added to the main window:

var settingsWindow = Ti.UI.createWindow({
    orientationModes: [Ti.UI.PORTRAIT],
    width: Ti.Platform.displayCaps.platformWidth,
    height: Ti.Platform.displayCaps.platformHeight,
    backgroundGradient: gradients.currentSettingsGradient(),
    navBarHidden: true,
});

settingsWindow.add(settingsScrollView);

The entire source code in settings.js:

https://github.com/codingisacopingstrategy/raduga/blob/aaa84a9fcaac14a7e2f1f248456690f78a393d7b/Resources/settings.js


Viewing all articles
Browse latest Browse all 8068

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>