Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #1
    Ext User
    Join Date
    May 2007
    Posts
    12
    Vote Rating
    0
    yew98 is on a distinguished road

      0  

    Default Is there any log utility in ext?

    Is there any log utility in ext?


    Hi everyone,
    I am new to ext. Is there any log utility in ext already? I search the api and forum but get nothing. now, I use a logger named jslog, but it looks not as pretty as ext.
    Thank you

  2. #2
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,496
    Vote Rating
    44
    Animal has a spectacular aura about Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Not included with Ext. It's a common requirement though. You culd try writing an Ext.ux.Logger extension to share!

  3. #3
    Ext User
    Join Date
    May 2007
    Posts
    12
    Vote Rating
    0
    yew98 is on a distinguished road

      0  

    Default


    ok, i'll have try. thank you

  4. #4
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,496
    Vote Rating
    44
    Animal has a spectacular aura about Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    I've made a very sinmple start.

    Drop this file into examples/layout.

    When you press the 'Add Tab' and 'Add Grid' buttons it logs messages.

    The singleton object Ext.ux.Logger isa Window, and has all the methods and behaviours of Ext.Window.

    Code:
    <html>
    <head>
      <title>Complex Layout</title>
    	<link rel="stylesheet" type="text/css" href="../../resources/css/ext-all.css" />
        
        <!-- GC -->
     	<!-- LIBS -->
     	<script type="text/javascript" src="../../adapter/ext/ext-base.js"></script>
     	<!-- ENDLIBS -->
    
        <script type="text/javascript" src="../../ext-all-debug.js"></script>
        <script type="text/javascript" src="../code-display.js"></script>
      	<style>
      	.x-log-entry { }
      	.x-log-entry .x-log-level {
      		float:left;
      		width:4em;
      		text-align:center;
      		margin-right: 3px 
      	}
      	.x-log-entry .x-log-time {
      		margin-right: 3px 
      	}
      	.x-log-entry .x-log-message {
      		margin-right: 3px 
      	}
      	.x-log-debug { background-color: #46c }
      	.x-log-info { background-color: green }
      	.x-log-warning { background-color: yellow }
      	.x-log-error { background-color: red }
      	</style>
      	<script type="text/javascript">
    Ext.ux.Logger = function() {
    	var tpl = new Ext.Template("<div class='x-log-entry'><div class='x-log-level x-log-{0:lowercase}'>" +
    		"{0:capitalize}</div><span class='x-log-time'>{2:date('H:i:s.u')}</span>" +
    		"<span class='x-log-message'>{1}</span></div>");
    	
    	return Ext.apply(new Ext.Window({
    			title: 'Ext Logger',
    			closeAction: 'hide',
    			height: 200,
    			minHeight: 200,
    			width: 400,
    			autoScroll: true,
    			buttons: [{
    			    text: 'Clear',
    			    handler: function() {
    			    	Ext.ux.Logger.body.update('');
    			    }
    			}]
    		}), {
    			debug: function(msg) {
    				tpl.insertFirst(this.body, ['debug', msg, new Date()], true).scrollIntoView(this.body);
    			},
    
    			info: function(msg) {
    				tpl.insertFirst(this.body, ['info', msg, new Date()], true).scrollIntoView(this.body);
    			},
    
    			warning: function(msg) {
    				tpl.insertFirst(this.body, ['warning', msg, new Date()], true).scrollIntoView(this.body);
    			},
    
    			error: function(msg) {
    				tpl.insertFirst(this.body, ['error', msg, new Date()], true).scrollIntoView(this.body);
    			}
    		});
    }();
    
    Array.prototype.contains = function(element) {
        for (var i = 0; i < this.length; i++) {
                if (this[i] == element) {
                    return true;
                }
        }        
    	return false;
    };
    
    Ext.override(Ext.Panel, {
    	makeDockable: function() {
    		var o = this.ownerCt;
    		if (!o || !(o instanceof Ext.TabPanel)) {
    			return;
    		}
    		Ext.fly(o.getTabEl(this)).on("dblclick", this.undock, this);
    	},
    	
    	undock: function() {
    		var h = this.getEl().getHeight();
    		var w = this.getEl().getWidth();
    		var o = this.ownerCt;
    		o.remove(this);
    		var win;
    		win = new Ext.Window({
    			renderTo: Ext.getBody(),
    			title: this.title,
    			constrain: true,
    			items: this,
    			tools: [{
    				id: 'pin',
    				qtip: 'Redock to original parent',
    				handler: function() {
    					win.remove(this);
    					o.add(this);
    					o.setActiveTab(this);
    					o.doLayout();
    					win.destroy();
    					this.makeDockable(); // The tab selector is new.
    				},
    				scope: this
    			}]
    		});
    		win.setHeight(h);
    		win.setWidth(w);
    		o.doLayout();
    		win.show();
    	}
    });
    
        Ext.onReady(function(){
       Ext.ux.Logger.show();
            var newTabCount = 0;
            var newGridCount = 0;
    		var viewport = new Ext.Viewport({
                layout:'border',
                items:[
                    new Ext.BoxComponent({ // raw
                        region:'north',
                        el: 'north',
                        height:32
                    }),{
                        region:'south',
                        contentEl: 'south',
                        split:true,
                        height: 100,
                        minSize: 100,
                        maxSize: 200,
                        collapsible: true,
                        title:'South',
                        margins:'0 0 0 0'
                    }, {
                        region:'east',
                        title: 'East Side',
                        collapsible: true,
                        split:true,
                        width: 225,
                        minSize: 175,
                        maxSize: 400,
                        layout:'fit',
                        margins:'0 5 0 0',
                        items:
                            new Ext.TabPanel({
                                border:false,
                                activeTab:1,
                                tabPosition:'bottom',
                                items:[{
                                    html:'<p>A TabPanel component can be a region.</p>',
                                    title: 'A Tab',
                                    autoScroll:true
                                },
                                new Ext.grid.PropertyGrid({
                                    title: 'Property Grid',
                                    closable: true,
                                    source: {
                                        "(name)": "Properties Grid",
                                        "grouping": false,
                                        "autoFitColumns": true,
                                        "productionQuality": false,
                                        "created": new Date(Date.parse('10/15/2006')),
                                        "tested": false,
                                        "version": .01,
                                        "borderWidth": 1
                                    }
                                })]
                        	})
                     },{
                        region:'west',
                        id:'west-panel',
                        title:'West',
                        split:true,
                        width: 200,
                        minSize: 175,
                        maxSize: 400,
                        collapsible: true,
                        margins:'0 0 0 5',
                        layout:'accordion',
                        layoutConfig:{
                            animate:true
                        },
                        items: [{
                            contentEl: 'west',
                            title:'Navigation',
                            border:false,
                            iconCls:'nav'
                        },{
                            title:'Settings',
                            html:'<p>Some settings in here.</p>',
                            border:false,
                            iconCls:'settings'
                        }]
                    },
                    new Ext.TabPanel({
                        id: 'center-tab-panel',
                        region:'center',
                        deferredRender:false,
    			        enableTabScroll:true,
                        activeTab:0,
                        items:[{
                        	id: 'foo',
                            contentEl:'center1',
                            title: 'Close Me',
                            closable:true,
                            autoScroll:true
                        },{
                            contentEl:'center2',
                            title: 'Center Panel',
                            autoScroll:true
                        }],
                        buttons: [{
                            text: "Add Tab",
                            handler: function() {
                                var tp = Ext.getCmp('center-tab-panel');
                                tp.add({
                                    title: "Dynamically added Panel " + (++newTabCount),
                                    closable: true,
                                    autoLoad: 'add-tab-code.html'
                                });
                                tp.doLayout();
                                tp.setActiveTab(tp.items.getCount() - 1);
                                Ext.ux.Logger.debug("Added tab " + newTabCount);
                            }
                        }, {
                            text: "Add Grid",
                            handler: function() {
                            	Ext.Ajax.request({
                            		url: 'create-grid.js',
                            		success: function(response) {
    		                            var tp = Ext.getCmp('center-tab-panel');
    		                            tp.add(eval(response.responseText)).setTitle("Dynamically added Grid " + (++newGridCount));
    		                            tp.doLayout();
    		                            tp.setActiveTab(tp.items.getCount() - 1);
    		                            Ext.ux.Logger.debug("Added grid " + tp.items.getCount());
                            		}
                            	});
                            }
                        }]
                    })
                 ]
            });
        });
    	</script>
    </head>
    <body>
    <script type="text/javascript" src="../examples.js"></script><!-- EXAMPLES -->
      <div id="west">
        <p>Hi. I'm the west panel.</p>
      </div>
      <div id="north">
        <p>north - generally for menus, toolbars and/or advertisements</p>
      </div>
      <div id="center2">
            <a id="hideit" href="#">Toggle the west region</a>
                <p>
                My closable attribute is set to false so you can't close me. The other center panels can be closed.</p>
            <p>The center panel automatically grows to fit the remaining space in the container that isn't taken up by the border regions.</p>
            <hr>
            <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Sed metus nibh, sodales a, porta at, vulputate eget, dui. Pellentesque ut nisl. Maecenas tortor turpis, interdum non, sodales non, iaculis ac, lacus. Vestibulum auctor, tortor quis iaculis malesuada, libero lectus bibendum purus, sit amet tincidunt quam turpis vel lacus. In pellentesque nisl non sem. Suspendisse nunc sem, pretium eget, cursus a, fringilla vel, urna. Aliquam commodo ullamcorper erat. Nullam vel justo in neque porttitor laoreet. Aenean lacus dui, consequat eu, adipiscing eget, nonummy non, nisi. Morbi nunc est, dignissim non, ornare sed, luctus eu, massa. Vivamus eget quam. Vivamus tincidunt diam nec urna. Curabitur velit. Quisque dolor magna, ornare sed, elementum porta, luctus in, leo.</p>
            <p>Donec quis dui. Sed imperdiet. Nunc consequat, est eu sollicitudin gravida, mauris ligula lacinia mauris, eu porta dui nisl in velit. Nam congue, odio id auctor nonummy, augue lectus euismod nunc, in tristique turpis dolor sed urna. Donec sit amet quam eget diam fermentum pharetra. Integer tincidunt arcu ut purus. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Nulla blandit malesuada odio. Nam augue. Aenean molestie sapien in mi. Suspendisse tincidunt. Pellentesque tempus dui vitae sapien. Donec aliquam ipsum sit amet pede. Sed scelerisque mi a erat. Curabitur rutrum ullamcorper risus. Maecenas et lorem ut felis dictum viverra. Fusce sem. Donec pharetra nibh sit amet sapien.</p>
            <p>Aenean ut orci sed ligula consectetuer pretium. Aliquam odio. Nam pellentesque enim. Nam tincidunt condimentum nisi. Maecenas convallis luctus ligula. Donec accumsan ornare risus. Vestibulum id magna a nunc posuere laoreet. Integer iaculis leo vitae nibh. Nam vulputate, mauris vitae luctus pharetra, pede neque bibendum tellus, facilisis commodo diam nisi eget lacus. Duis consectetuer pulvinar nisi. Cras interdum ultricies sem. Nullam tristique. Suspendisse elementum purus eu nisl. Nulla facilisi. Phasellus ultricies ullamcorper lorem. Sed euismod ante vitae lacus. Nam nunc leo, congue vehicula, luctus ac, tempus non, ante. Morbi suscipit purus a nulla. Sed eu diam.</p>
            <p>Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Cras imperdiet felis id velit. Ut non quam at sem dictum ullamcorper. Vestibulum pharetra purus sed pede. Aliquam ultrices, nunc in varius mattis, felis justo pretium magna, eget laoreet justo eros id eros. Aliquam elementum diam fringilla nulla. Praesent laoreet sapien vel metus. Cras tempus, sapien condimentum dictum dapibus, lorem augue fringilla orci, ut tincidunt eros nisi eget turpis. Nullam nunc nunc, eleifend et, dictum et, pharetra a, neque. Ut feugiat. Aliquam erat volutpat. Donec pretium odio nec felis. Phasellus sagittis lacus eget sapien. Donec est. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae;</p>
            <p>Vestibulum semper. Nullam non odio. Aliquam quam. Mauris eu lectus non nunc auctor ullamcorper. Sed tincidunt molestie enim. Phasellus lobortis justo sit amet quam. Duis nulla erat, varius a, cursus in, tempor sollicitudin, mauris. Aliquam mi velit, consectetuer mattis, consequat tristique, pulvinar ac, nisl. Aliquam mattis vehicula elit. Proin quis leo sed tellus scelerisque molestie. Quisque luctus. Integer mattis. Donec id augue sed leo aliquam egestas. Quisque in sem. Donec dictum enim in dolor. Praesent non erat. Nulla ultrices vestibulum quam.</p>
            <p>Duis hendrerit, est vel lobortis sagittis, tortor erat scelerisque tortor, sed pellentesque sem enim id metus. Maecenas at pede. Nulla velit libero, dictum at, mattis quis, sagittis vel, ante. Phasellus faucibus rutrum dui. Cras mauris elit, bibendum at, feugiat non, porta id, neque. Nulla et felis nec odio mollis vehicula. Donec elementum tincidunt mauris. Duis vel dui. Fusce iaculis enim ac nulla. In risus.</p>
            <p>Donec gravida. Donec et enim. Morbi sollicitudin, lacus a facilisis pulvinar, odio turpis dapibus elit, in tincidunt turpis felis nec libero. Nam vestibulum tempus ipsum. In hac habitasse platea dictumst. Nulla facilisi. Donec semper ligula. Donec commodo tortor in quam. Etiam massa. Ut tempus ligula eget tellus. Curabitur id velit ut velit varius commodo. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nulla facilisi. Fusce ornare pellentesque libero. Nunc rhoncus. Suspendisse potenti. Ut consequat, leo eu accumsan vehicula, justo sem lobortis elit, ac sollicitudin ipsum neque nec ante.</p>
            <p>Aliquam elementum mauris id sem. Vivamus varius, est ut nonummy consectetuer, nulla quam bibendum velit, ac gravida nisi felis sit amet urna. Aliquam nec risus. Maecenas lacinia purus ut velit. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Suspendisse sit amet dui vitae lacus fermentum sodales. Donec varius dapibus nisl. Praesent at velit id risus convallis bibendum. Aliquam felis nibh, rutrum nec, blandit non, mattis sit amet, magna. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Etiam varius dignissim nibh. Quisque id orci ac ante hendrerit molestie. Aliquam malesuada enim non neque.</p>
      </div>
      <div id="center1">
            <p><b>Done reading me? Close me by clicking the X in the top right corner.</b></p>
            <p>Vestibulum semper. Nullam non odio. Aliquam quam. Mauris eu lectus non nunc auctor ullamcorper. Sed tincidunt molestie enim. Phasellus lobortis justo sit amet quam. Duis nulla erat, varius a, cursus in, tempor sollicitudin, mauris. Aliquam mi velit, consectetuer mattis, consequat tristique, pulvinar ac, nisl. Aliquam mattis vehicula elit. Proin quis leo sed tellus scelerisque molestie. Quisque luctus. Integer mattis. Donec id augue sed leo aliquam egestas. Quisque in sem. Donec dictum enim in dolor. Praesent non erat. Nulla ultrices vestibulum quam.</p>
            <p>Duis hendrerit, est vel lobortis sagittis, tortor erat scelerisque tortor, sed pellentesque sem enim id metus. Maecenas at pede. Nulla velit libero, dictum at, mattis quis, sagittis vel, ante. Phasellus faucibus rutrum dui. Cras mauris elit, bibendum at, feugiat non, porta id, neque. Nulla et felis nec odio mollis vehicula. Donec elementum tincidunt mauris. Duis vel dui. Fusce iaculis enim ac nulla. In risus.</p>
            <p>Donec gravida. Donec et enim. Morbi sollicitudin, lacus a facilisis pulvinar, odio turpis dapibus elit, in tincidunt turpis felis nec libero. Nam vestibulum tempus ipsum. In hac habitasse platea dictumst. Nulla facilisi. Donec semper ligula. Donec commodo tortor in quam. Etiam massa. Ut tempus ligula eget tellus. Curabitur id velit ut velit varius commodo. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nulla facilisi. Fusce ornare pellentesque libero. Nunc rhoncus. Suspendisse potenti. Ut consequat, leo eu accumsan vehicula, justo sem lobortis elit, ac sollicitudin ipsum neque nec ante.</p>
            <p>Aliquam elementum mauris id sem. Vivamus varius, est ut nonummy consectetuer, nulla quam bibendum velit, ac gravida nisi felis sit amet urna. Aliquam nec risus. Maecenas lacinia purus ut velit. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Suspendisse sit amet dui vitae lacus fermentum sodales. Donec varius dapibus nisl. Praesent at velit id risus convallis bibendum. Aliquam felis nibh, rutrum nec, blandit non, mattis sit amet, magna. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Etiam varius dignissim nibh. Quisque id orci ac ante hendrerit molestie. Aliquam malesuada enim non neque.</p>
      </div>
      <div id="props-panel" style="width:200px;height:200px;overflow:hidden;">
      </div>
      <div id="south">
        <p>south - generally for informational stuff, also could be for status bar</p>
      </div>
    
     </body>
    </html>

  5. #5
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,496
    Vote Rating
    44
    Animal has a spectacular aura about Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    It already looks 10 times better than that jslog thing.

  6. #6
    Ext User
    Join Date
    Oct 2007
    Location
    Central England
    Posts
    169
    Vote Rating
    0
    tjcrowder is on a distinguished road

      0  

    Default


    Cool start! Could optionally offer integration with Firebug's console (for those running Firebug) via the console object's log, debug, error, info, and warn methods. Dojo does that: There's a Dojo logger, which when you're running under Firebug (and if you haven't disabled it) logs to Firebug; otherwise it appends a div to the end of your page (to which I went: yeech -- I much prefer your solution, Animal, of putting up a logging window).
    T.J. Crowder
    tj / crowdersoftware / com

  7. #7
    Ext User
    Join Date
    May 2007
    Posts
    12
    Vote Rating
    0
    yew98 is on a distinguished road

      0  

    Default


    Thank you Animal. It works pretty well.

  8. #8
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,059
    Vote Rating
    113
    aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold

      0  

    Default


    There is also a pretty neat logger built into the ext-all-debug.js packaged file. If you check out the src directory it is named debug.js.

    It includes Ext.log, Ext.logf, Ext.dump, Ext.time and Ext.timeEnd.

    I don't know how many people know/use this tool as I haven't seen it documented anywhere but it can certainly be useful in IE when you need to print some stuff out and don't have Firebug available to you
    Aaron Conran
    @aconran
    Sencha Architect Development Team