Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[6_1_X][TIMOB-24728] Fix TiScrollViewLayout.getLayout() #9078

Merged
merged 2 commits into from May 24, 2017

Conversation

garymathews
Copy link
Contributor

  • Fix TiScrollViewLayout getLayout method
TEST CASE
var win1 = Ti.UI.createWindow();

var button = Ti.UI.createButton({
    title: "open window"
});

button.addEventListener("click", function() {
    createScrollViewWindow();
});

win1.add(button);
win1.open();

function createScrollViewWindow() {
    var win = Ti.UI.createWindow({
        title: "test scrollview",
        backgroundColor: '#fff'
    });

    var scrollView = Ti.UI.createScrollView({
        height: Ti.UI.FILL,
        layout: 'vertical'
    });

    var label = Ti.UI.createLabel({
        text: "scrollview",
        color: "#000"
    });
    var buttonClose = Ti.UI.createButton({
        title: "close"
    });
    buttonClose.addEventListener("click", function() {
        win.close();
    });

    var row1 = Ti.UI.createTableViewRow({});
    var labelrow1 = Ti.UI.createLabel({
        text: "row 1",
        color: "#000",
    });
    row1.add(labelrow1);

    var table = Ti.UI.createTableView({
        data: [row1],
        borderColor: "transparent",
        rowBackgroundColor: "white",
        height: Ti.UI.SIZE
    });

    scrollView.add(label);
    scrollView.add(table);
    scrollView.add(buttonClose);
    win.add(scrollView);
    win.open();
}

JIRA Ticket

Copy link
Contributor

@jquick-axway jquick-axway left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CR: Pass

@longton95 longton95 self-requested a review May 24, 2017 16:13
Copy link
Contributor

@longton95 longton95 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FR passed.

Tested using the test case above, the application no longer crashes when the window containing a TableView in a ScrollView is closed.

ENV

SDK Version : Local 6.1.0
Mac OS Version : 10.12.4
Appc CLI : 6.2.1
Appc NPM : 4.2.9
Node : v6.10.3
Device: Nexus 5x(6.0.1), Pixel XL(7.1.2)
Emulator: (7.0), (6.0), (4.4.2)

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

Successfully merging this pull request may close these issues.

None yet

4 participants