pec1985 / TiSMSView

Expandable Text Area Module - iOS - Titanium
Other
60 stars 18 forks source link

addLabel in recent version? #43

Closed caspahouzer closed 12 years ago

caspahouzer commented 13 years ago

After successful compiling the newest version of Ti.smsview, everthing looks fine. but..

I tried to use the addLabel function. The response is:

Result of expression 'smsView.addLabel' [undefined] is not a function.

Here is some code:

var smsView = Ti.SMSView.createView({
        //maxLines:6,               // <--- Defaults to 4
        //minLines:2,               // <--- Defaults to 1
        backgroundColor : config.backgroundColor, // <--- Defaults to #dae1eb
        assets : 'assets', // <--- Defaults to nothing, smsview.bundle can be places in the Resources dir
        // sendColor: 'Green',      // <--- Defaults to "Green"
        recieveColor : 'Gray', // <--- Defaults to "White"
        // selectedColor: 'Blue',   // <--- Defaults to "Blue"
        // editable: true,          // <--- Defaults to true, do no change it
        // animated: false,         // <--- Defaults to true
        // buttonTitle:L('send'),   // <--- Defaults to "Send"
        // font: { fontSize: 12 ... },  // <--- Defaults to... can't remember
        // autocorrect: false,      // <--- Defaults to true
        // textAlignment: 'left',   // <--- Defaults to left
        // textColor: 'blue',       // <--- Defaults to "black"
        returnType : Ti.SMSView.RETURNKEY_DONE // <---- Defaults to Ti.SMSView.RETURNKEY_DEFAULT
        // camButton : true             // <--- Defaults to false
    });

smsView.addEventListener('buttonClicked', function(e) {
        smsView.addLabel(new Date()+'');
        smsView.sendMessage(e.value);
    });
pec1985 commented 12 years ago

Are you still having the same issue with the latest code?

caspahouzer commented 12 years ago

nope. 1.1 seems to be alright