1. #11
    Sencha User
    Join Date
    Aug 2008
    Posts
    5
    Vote Rating
    0
    gakaki is on a distinguished road

      0  

    Post Ext.override can do this tood

    Ext.override can do this tood


    Ext.override(Ext.picker,{
    'doneButton':'quewqeqewqewqewqeqwewqe',
    'cancelButton':'canceladsfadsfafadsffads'

    })

  2. #12
    Sencha User
    Join Date
    Jan 2012
    Posts
    3
    Vote Rating
    0
    ujjwal_kumar_roy is on a distinguished road

      0  

    Default Uses of External Date Picker build with jquerry in sencha touch 2

    Uses of External Date Picker build with jquerry in sencha touch 2


    Actually i want to make an application where an external jq date picker is to be insert in sencha touch. but i can't do it. can any one help me.

  3. #13
    Sencha User
    Join Date
    Feb 2012
    Posts
    15
    Vote Rating
    0
    tine_m is on a distinguished road

      0  

    Default localization in sencha touch 2 (example)

    localization in sencha touch 2 (example)


    Hi!

    I was searching for that topic (for SENCHA TOUCH 2) on the internets for hours without any luck.. I wondered how to apply the JS file found in /src/locale/ to the sencha app, but whatever I did, the DatePicker did not get localized.


    Finnaly I found a solution, and maybe this will save some time to someone....
    again, this is solution for SENCHA TOUCH 2.0!

    1. I edited and translated the file /src/locale/ext-lang-en.js. I noticed that in this file, there was still depricated function "Ext.override" so that has to be fixed. And "Date" should be replaced with "Ext.Date". Also I put the whole script into a function in Ext.onReady event. Here is my final file (translated for Slovenian locale, but you will get the point...):
    Code:
    Ext.onReady(function() {
    	Ext.Date.dayNames = [
    		'Nedelja',
    		'Ponedeljek',
    		'Torek',
    		'Sreda',
    		'Četrtek',
    		'Petek',
    		'Sobota'
    	];
    
    
    	Ext.Date.monthNames = [
    		'Januar',
    		'Februar',
    		'Marc',
    		'April',
    		'Maj',
    		'Junij',
    		'Julij',
    		'Avgust',
    		'September',
    		'Oktober',
    		'November',
    		'December'
    	];
    
    
    	Ext.Date.monthNumbers = {
    		'Jan': 0,
    		'Feb': 1,
    		'Mar': 2,
    		'Apr': 3,
    		'Maj': 4,
    		'Jun': 5,
    		'Jul': 6,
    		'Avg': 7,
    		'Sep': 8,
    		'Okt': 9,
    		'Nov': 10,
    		'Dec': 11
    	};
    
    
    	Ext.Date.getShortMonthName = function(month) {
    		return Date.monthNames[month].substring(0, 3);
    	};
    
    
    	Ext.Date.getShortDayName = function(day) {
    		return Date.dayNames[day].substring(0, 3);
    	};
    
    
    	Ext.Date.getMonthNumber = function(name) {
    	  return Date.monthNumbers[name.substring(0, 1).toUpperCase() + name.substring(1, 3).toLowerCase()];
    	};
    
    
    	Ext.Date.parseCodes.S.s = '(?:st|nd|rd|th)';
    
    
    	if (Ext.picker.Picker){
    		Ext.define('Ext.picker.Picker', {
    			override: 'Ext.picker.Picker',
    			config:{
    				doneButton: 'Izberi' ,
    				cancelButton: 'Prekliči'
    			}
    		});
    	}
    
    
    	if (Ext.picker.Date) {
    		//debugger;
    		
    		Ext.define('Ext.picker.Date', {
    			override: 'Ext.picker.Date',
    			config:{
    				doneButton: 'Izberi' ,
    				cancelButton: 'Prekliči',
    				dayText: 'Dan',
    				monthText: 'Mesec',
    				yearText: 'Leto',
    				slotOrder: ['day', 'month', 'year']   
    			}			
    		});
    	}
    	
    	
    	if(Ext.IndexBar){
    		Ext.define('Ext.IndexBar', {
    			override: 'Ext.IndexBar',
    			config:
    			{
    				letters: ['A', 'B', 'C', 'Č', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'Š', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', 'Ž']
    			}
    		});
    	}
    
    
    	if(Ext.NestedList){
    		Ext.define('Ext.NestedList', {
    			override: 'Ext.NestedList',
    			config:{
    				backText: 'Nazaj',
    				loadingText: 'Nalagam...',
    				emptyText: 'Ni podatkov za prikaz'
    			}
    		});
    	}
    
    
    	if(Ext.util.Format){
    		Ext.util.Format.defaultDateFormat = 'd.m.Y';
    	}
    
    
    	if(Ext.MessageBox){
    		Ext.MessageBox.OK.text = 'V redu';
    		Ext.MessageBox.CANCEL.text = 'Prekliči';
    		Ext.MessageBox.YES.text = 'Da';
    		Ext.MessageBox.NO.text = 'Ne';
    	}
    });
    2.) I saved the file to <app_dir>/locale/ext-lang-si.js. In my index.html I added the line AFTER app.js script and that was it.
    Code:
    <script type="text/javascript" src="/sencha-touch-2.0.1.1/sencha-touch-debug.js"></script>
        <script type="text/javascript" src="app.js"></script>
        <script type="text/javascript" src="locale/ext-lang-si.js"></script>
    Hopefully someone will find this useful.

    P.S.: I have probably misplaced this thread, but this is where google directed me most of the times, and I believe that so will do for others... sorry for inconvenience.

  4. #14
    Sencha User
    Join Date
    Aug 2012
    Posts
    16
    Vote Rating
    0
    GillesK is on a distinguished road

      0  

    Default localization in sencha touch 2 (example)

    localization in sencha touch 2 (example)


    Hello,

    I have tried tine_m solution but my sencha touch 2.0 (2.0.1.1) is slightly different since I don´t have
    any reference to app.js in the index.html and I load microloader/development.js.
    The solution does not work for me

    Any Clue ?

  5. #15
    Sencha User
    Join Date
    Feb 2012
    Posts
    15
    Vote Rating
    0
    tine_m is on a distinguished road

      0  

    Default


    If you use microloader, then make sure that you put localization script (for example "locale/ext-lang-si.js") into your app.json like this:

    Code:
    {
    Code:
    ... 
    "js": [
           {
                "path": "sdk/sencha-touch.js"
            },
            
            {
                "path": "app.js",
                "bundle": true,
                "update": "delta"
            },
            { 
                "path": "locale/ext-lang-si.js",
                "update": "delta"  
            }
        ],
    ....
    /**
         * Extra resources to be copied along when build
         */
        "resources": [
            "img",
            "css",
            "locale",
            
        ],
    }
    
    
    I hope that helps.

Similar Threads

  1. Localization in Sench Touch
    By Buckeye in forum Sencha Touch 1.x: Discussion
    Replies: 1
    Last Post: 28 Aug 2011, 9:21 PM
  2. [DUPE-653] Touch 1.0.1 scrolls to end of page on simple touch.
    By stevek in forum Sencha Touch 1.x: Bugs
    Replies: 2
    Last Post: 23 Dec 2010, 3:45 PM
  3. Sencha Touch on iPhone v1 / iPod touch v1 ?
    By palnap in forum Sencha Touch 1.x: Discussion
    Replies: 4
    Last Post: 28 Oct 2010, 5:30 PM
  4. [FIXED-202] Error in sench/examples/geocongress
    By efx in forum Sencha Touch 1.x: Bugs
    Replies: 12
    Last Post: 8 Sep 2010, 1:25 PM

Thread Participants: 9

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi