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.

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Ext User
    Join Date
    Jul 2007
    Location
    Florida
    Posts
    9,996
    Vote Rating
    5
    mjlecomte will become famous soon enough mjlecomte will become famous soon enough

      0  

    Default [FIXED-745][2.x, 3.x] headersDisabled changes on column drag

    [FIXED-745][2.x, 3.x] headersDisabled changes on column drag


    Mystix is completely to blame for me posting this.

    If you drop this into the array-grid demo:
    Code:
        // create the Grid
        var grid = new Ext.grid.GridPanel({
            viewConfig: {
                headersDisabled: true // disable grid headers
            },
            store: store,
    When you mouse over and click on the headers they don't change in appearance, nor do they sort, or show the trigger. Fair enough, that's what I expected it should do. But now, drag the columns to reorder them. Low and behold, headersDisabled == false now, all features of headers appear to be restored.

    It's almost as if there's a nifty config for:
    Code:
    enableHeadersOnDrag: true

  2. #2
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    80
    Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of

      0  

    Default


    SplitDragZone uses headersDisabled, so it's not a property you can use in the GridView config.

    Or you would have to backup the original value, e.g.
    Code:
    Ext.override(Ext.grid.GridView.SplitDragZone, {
    	b4StartDrag : function(x, y){
    		this.oldHeadersDisabled = this.view.headersDisabled;
    		this.view.headersDisabled = true;
    		var h = this.view.mainWrap.getHeight();
    		this.marker.setHeight(h);
    		this.marker.show();
    		this.marker.alignTo(this.view.getHeaderCell(this.cellIndex), 'tl-tl', [-2, 0]);
    		this.proxy.setHeight(h);
    		var w = this.cm.getColumnWidth(this.cellIndex);
    		var minw = Math.max(w-this.grid.minColumnWidth, 0);
    		this.resetConstraints();
    		this.setXConstraint(minw, 1000);
    		this.setYConstraint(0, 0);
    		this.minX = x - minw;
    		this.maxX = x + 1000;
    		this.startPos = x;
    		Ext.dd.DDProxy.prototype.b4StartDrag.call(this, x, y);
    	},
    	endDrag : function(e){
    		this.marker.hide();
    		var endX = Math.max(this.minX, e.getPageX());
    		var diff = endX - this.startPos;
    		this.view.onColumnSplitterMoved(this.cellIndex, this.cm.getColumnWidth(this.cellIndex)+diff);
    	},
    	onMouseUp : function(e){
    		var v = this.view, d = this.oldHeadersDisabled;
    		setTimeout(function(){
    			v.headersDisabled = d;
    		}, 50);
    	}
    });
    Last edited by Condor; 5 Mar 2009 at 7:29 AM. Reason: Use onMouseUp instead of endDrag + this.view fix

  3. #3
    Sencha - Community Support Team mystix's Avatar
    Join Date
    Mar 2007
    Location
    Singapore
    Posts
    6,236
    Vote Rating
    5
    mystix will become famous soon enough

      0  

    Default


    Quote Originally Posted by mjlecomte View Post
    Mystix is completely to blame for me posting this.


    D'oh...

  4. #4
    Ext User
    Join Date
    Jul 2007
    Location
    Florida
    Posts
    9,996
    Vote Rating
    5
    mjlecomte will become famous soon enough mjlecomte will become famous soon enough

      0  

    Default


    Quote Originally Posted by Condor View Post
    SplitDragZone uses headersDisabled, so it's not a property you can use in the GridView config.
    Do you need to specify the view?

    Code:
    Ext.override(Ext.grid.GridView.SplitDragZone, {
    	b4StartDrag : function(x, y){
    		this.oldHeadersDisabled = this.view.headersDisabled;
    		this.view.headersDisabled = true;
    		var h = this.view.mainWrap.getHeight();
    		this.marker.setHeight(h);
    		this.marker.show();
    		this.marker.alignTo(this.view.getHeaderCell(this.cellIndex), 'tl-tl', [-2, 0]);
    		this.proxy.setHeight(h);
    		var w = this.cm.getColumnWidth(this.cellIndex);
    		var minw = Math.max(w-this.grid.minColumnWidth, 0);
    		this.resetConstraints();
    		this.setXConstraint(minw, 1000);
    		this.setYConstraint(0, 0);
    		this.minX = x - minw;
    		this.maxX = x + 1000;
    		this.startPos = x;
    		Ext.dd.DDProxy.prototype.b4StartDrag.call(this, x, y);
    	},
    	endDrag : function(e){
    		this.marker.hide();
    		var v = this.view;
    		var endX = Math.max(this.minX, e.getPageX());
    		var diff = endX - this.startPos;
    		v.onColumnSplitterMoved(this.cellIndex, this.cm.getColumnWidth(this.cellIndex)+diff);
    	},
    	onMouseUp : function(e){
    		var oldHeadersDisabled = this.oldHeadersDisabled;
    
    		var v = this.view;
    
    		setTimeout(function(){
    			v.headersDisabled = oldHeadersDisabled;
    		}, 50);
    	}
    });

  5. #5
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Vote Rating
    80
    Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of

      0  

    Default


    Corrected (that's what you get when you write code in the forum editor)

  6. #6
    Sencha - Community Support Team mystix's Avatar
    Join Date
    Mar 2007
    Location
    Singapore
    Posts
    6,236
    Vote Rating
    5
    mystix will become famous soon enough

      0  

    Default


    Quote Originally Posted by Condor View Post
    Corrected (that's what you get when you write code in the forum editor)
    off-topic: one day, all forum editors will be like this:
    https://bespin.mozilla.com/

  7. #7
    Sencha Premium Member Wedgie's Avatar
    Join Date
    Jan 2009
    Location
    Melbourne, Australia
    Posts
    76
    Vote Rating
    0
    Wedgie is on a distinguished road

      0  

    Exclamation


    Hi guys,
    This one caught me out badly. Luckily I found this thread before spending too many hours on it. Also, the problem is not obvious - I was just lucky to pick it up in testing.

    The GridView headersDisabled config is still documented in 3.1.1, but it's also still broken by column dragging or resizing. So it looks like either it needs to come out of the docs or get fixed per the suggestion. I can confirm the bug in 3.0.3 by testing, and code inspection of GridView.js in 3.1.1 indicates it's still there.

    Personally my preference is for it to be fixed in the code since you need to be able to disable sorting without also disabling column resizing, and there will be lots of deployed systems out there that have relied on it - probably not knowing that it will break if the user clicks the wrong spot in the headers.

    Cheers

  8. #8
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,608
    Vote Rating
    580
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      0  

    Default


    Fixed in rev 6319.
    Evan Trimboli
    Sencha Developer
    Twitter - @evantrimboli
    Don't be afraid of the source code!