PDA

View Full Version : How can I set the doneText value in a Ext.form.Select --> picker



SimonFlack
16 Sep 2010, 2:37 AM
I am developing an application to be used in Norway and need to use Norwegian on buttons etc.

I am having trouble setting the "doneText" value on the picker that is created when a Select is tapped on a phone.

I have temporarily solved this by modifying ext-touch-debug.js so that Ext.form.Select now has a "doneText" property and using this value to set the pickers "doneText" property.

E.g

ext-touch.debug.js
**********************************************
22240: Ext.form.Select = Ext.extend(Ext.form.TextField, {
doneText: 'Done',

22288: onMaskTap : function() {
if (Ext.is.Phone) {
this.picker = new Ext.Picker({
doneText: this.doneText,

MyCode
**********************************************
register.timeTypesField = new Ext.form.Select({
doneText: 'Ferdig',


Is there another (proper) way to set a Select's "doneText" property?

SimonFlack
17 Sep 2010, 4:11 AM
no one?

evant
19 Sep 2010, 8:22 PM
Ext.form.Select.prototype.doneText = 'Foo';


You can create a locale file of your own by using the one under src/locale as a template. Seems we need to add a few things in there!

SimonFlack
19 Sep 2010, 9:51 PM
Thanks... I'm new to javascript.