Skip to content
This repository has been archived by the owner on Apr 8, 2021. It is now read-only.

ipad Popover, position beside nested view #162

Open
intellirolf opened this issue Apr 27, 2016 · 1 comment
Open

ipad Popover, position beside nested view #162

intellirolf opened this issue Apr 27, 2016 · 1 comment

Comments

@intellirolf
Copy link

Hi there, I'm having a problem with the positioning of a popover using Social.activityPopover().

Everything works fine, but as soon as the views are nested, the popover doesn't pop up beside the right view. Here's some code to reproduce the issue:

`var win = Ti.UI.createWindow({
backgroundColor : 'white'
});

var contentContainer = Ti.UI.createScrollView({
layout : "vertical",
backgroundColor : '#ff0'
});

var content1 = Ti.UI.createView({
width : '50%',
height : 100,
backgroundColor : '#f90'
});

var content2 = Ti.UI.createView({
width : '50%',
height : 100,
top : 100,
backgroundColor : '#f9c'
});
var content2Inner = Ti.UI.createView({
width : '50%',
height : 100,
backgroundColor : '#fcc'
});

contentContainer.add(content1);

content2.add(content2Inner);
contentContainer.add(content2);

var Social = require('dk.napp.social');
contentContainer.addEventListener("click", function(e) {
if (Social.isActivityViewSupported()) {//min iOS6 required
Social.activityPopover({
text : "share like a king!",
image : "pin.png",
// removeIcons:"print,sms,copy,contact,camera,mail",
view : content2Inner //source button
});
} else {
//implement fallback sharing..
}
});

win.add(contentContainer);
win.open(); `

There is a View 'contentContainer' with 2 views inside (content1, content2). Inside 'content2' there is another view 'content2Inner'.

When I use 'view : content1' (or 'content2') as the source view, it works. When I set the source view to 'content2Inner' the Popover appears on top of the Window, not beside 'content2Inner'.

@nuno
Copy link

nuno commented Nov 13, 2016

Fixed here #167 can you test?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants