This is a migrated thread and some comments may be shown as answers.

How to prevent the screen to be pulled up

2 Answers 198 Views
Apache Cordova
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Yohann
Top achievements
Rank 1
Yohann asked on 24 Oct 2014, 06:09 PM
Hello,

When sliding up or down an non-scrollable element in my view I get the entire screen pulled up, which doesn't give a native feeling.



How can I prevent that from happening ?




Also, I noticed that sliding through a long listview is not as smooth as I would like it to be.
I don't have any shadows in my css nor transparency. How should I handle that ?

Is this situation when native scrolling comes to hand?

I did :

app = new kendo.mobile.Application( $(document.body),
        {
            platform: {
                name: "ios",          // Mobile OS, can be "ios", "android", "blackberry", "wp", "meego"
                ios: true,            // Mobile OS name as a flag
                majorVersion: 7,      // Major OS version
                appMode: false,       // Whether running in browser or in AppMode/PhoneGap/Icenium.
                useNativeScrolling: true
            }
        });

when initializing kendo, but it's not good. Should I remove it ? is it automatically applied to every element in my DOM ?

Thank you for your advises

2 Answers, 1 is accepted

Sort by
0
Yohann
Top achievements
Rank 1
answered on 24 Oct 2014, 06:10 PM
Please see the images attached that demonstrates how the screen can be pulled up.
0
Tsvetina
Telerik team
answered on 29 Oct 2014, 01:41 PM
Hello Yohann,

This happens because of the Safari web view that runs the hybrid app, its default behavior is to make this "overscroll" effect. You can disable this behavior by doing the following:

1) Right-click the project name and select Edit Configuration -> iOS Config.xml.
2) Find this preference and change its value to true.

<preference name="DisallowOverscroll" value="false" />

3) Save the config file and re-deploy your application.

Additionally, you do not need to set the platform as an object. Just set platform: "ios7" and move the useNativeScrolling setting outside of the platform one:

app = new kendo.mobile.Application( $(document.body),
{
    platform: "ios7",
    useNativeScrolling: true
});

I hope this helps.

Regards,
Tsvetina
Telerik
 

Visit the Telerik Verified Plugins Marketplace and get the custom Cordova plugin you need, already tweaked to work seamlessly with AppBuilder.

 
Tags
Apache Cordova
Asked by
Yohann
Top achievements
Rank 1
Answers by
Yohann
Top achievements
Rank 1
Tsvetina
Telerik team
Share this question
or