Titanium JIRA Archive
Appcelerator Community (AC)

[AC-3037] ScrollView - "remove" method doesn't work

GitHub Issuen/a
TypeBug
Priorityn/a
StatusClosed
ResolutionDuplicate
Resolution Date2011-07-26T03:50:12.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
Labelsn/a
ReporterIvan Skugor
AssigneeTony Guntharp
Created2011-07-26T01:34:11.000+0000
Updated2016-03-08T07:48:04.000+0000

Description

Remove method of "ScrollView" component doesn't work. Here is simple example that demonstrates the issue:
var win = Ti.UI.createWindow({
    modal: true,
    backgroundColor: '#000',
    layout: 'vertical' 
});
 
var view = Ti.UI.createScrollView({
    layout: 'horizontal',
    height: 'auto'
});
 
var label = Ti.UI.createLabel({ text: 'Test' });
 
var tf = Ti.UI.createTextField({ width: 300 });
 
view.add(label);
view.add(tf);
 
win.add(view);
 
win.addEventListener('open', function() {
    setTimeout(function() { view.remove(label) }, 3000);
});
 
win.open();
Label should be removed after 3 seconds, but nothing happens. If you change "ScrollView" with "View" everything works fine.

Comments

  1. Paul Dowsett 2011-07-26

  2. Ivan Skugor 2011-07-26

    Hi Paul. I have tested my code. It's not missing "win.open()", you need to scroll down to see it. :) I'm using "open" event and "setTimeout" so you can easily see the problem. Example can be without that. I did open Q/A issue: [http://developer.appcelerator.com/question/123174/scrollview---remove-method-doesnt-work] But didn't search for old tickets, I forgot to do that, sorry about that.
  3. Ivan Skugor 2011-07-26

    Btw, Paul, you have small copy/paste error in your code posted to the TIMOB-3378: "ar win ..." instead of "var win ...". Also, IMHO, TIMOB-3378 should have higher priority, it's basic and important feature. :)
  4. Paul Dowsett 2011-08-30

    Closing issue. If any new information comes to light that justifies it, then please reopen.

JSON Source