Languages

Menu
Sites
Language
Naviframe & Rotation

Hi All,

All this while I had only one view of the App. The parent-child flow is like this

window->conformant->naviframe->box.

On rotating the device the entire scene was re-painted fine.

Now I added second view to my App. I am using naviframe_push().

On the first time launch of the App, the rotation works well on the first view. Navigate to second view, the second view works fine on rotation.

Now, come back to first view. The first view isn't working fine on rotation. It doesn't re-paint the whole scene.

Lets say I am in Vertical mode, I rotate it 90 degress, the view just rotates 90 degrees but the the scene is cut. Means the height and width of the widgets is not recalculated.

Am I missing anything?

Thanx,

Ashwini

Responses

3 Replies
Alex Dem

Hi,
Standard code snippet to support rotation is:
 

    if (elm_win_wm_rotation_supported_get(ad->win)) {
        int rots[4] = { 0, 90, 180, 270 };
        elm_win_wm_rotation_available_rotations_set(ad->win, (const int *)(&rots), 4);
    }

Also there is Naviframe control example in Tizen->native samples : 'UI Controls (elementary) sample application'. Looks like Naviframe should works without any additional steps.
Alexey.

Ashwini Kumar

Hi Alexey,

The snippet you mentioned is already in use in my code, as I do see the rotation happening.

But the trouble is its not proper rotation. The elements are not scaling to the full view port.

and as mentioned this happens only once I come back from the second view to First.

Thanx,

Ashwini

colin Rao

Possible you are miss set some size hint about the box. Could you share your sample code here, that's I can debuging base on your code. :)