Results 1 to 2 of 2

Thread: Dragging Buttons Between Panels

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default Dragging Buttons Between Panels

    Hey Guys,

    I have a button, and all I want to do is drag it from one panel to another. I've been trying for several hours now, and I can't seem to make my button drag at all, let alone between two panels.

    Here's my panel and button:
    Code:
                xtype: 'panel',
                region: 'west',
                split: true,
                border: false,
                itemId: 'menuPanel',
                maxWidth: 150,
                minWidth: 150,
                width: 150,
                bodyBorder: true,
                collapsible: false,
                title: 'Pieces',
                items: [
                    {
                        xtype: 'button',
                        alwaysOnTop: true,
                        constrain: true,
                        autoShow: true,
                        draggable: true,
                        floating: true,
                        height: 75,
                        width: 75,
                        text: 'Piece1'
                    }
                ]
    Here's a screenshot of what it looks like, all I want to do is drag the button from the "Pieces" panel to the "Content" panel: m81qwTv.jpg

    (also if you know how to make the "Pieces" panel unable to resize left-to-right that'd be nice, but I managed that by setting the min and max width to the same value, so it's not super important)


    I'm still pretty new to Sencha Architect, so any help you can give would be greatly appreciated!

    Thanks so much!
    - Kalashnikoven

  2. #2
    Sencha User
    Join Date
    Sep 2014
    Location
    Central Europe
    Posts
    795
    Answers
    103

    Default

    Hi Kalashnikoven

    You can drag the button from one panel to another in the Project Inspector. (It's on the right of the SA screen).

    M0xKwME.png

    To disable re-sizing of the panel, you need to select the panel in the Project Inspector.
    Than go to it's config (under the project Inspector). Find config resizable. And click on the icon next to the text "resizable", than you can select type boolean. The setting should change to the check-box. When you unchecked it, the panel should not longer be resizable.

    9rNuiO8.png



    Petr

Similar Threads

  1. How to enable dragging panels only in the title bar
    By ngd in forum Sencha Ext JS Q&A
    Replies: 1
    Last Post: 23 Sep 2012, 10:08 PM
  2. Make Buttons Switch Panels?
    By sammiller in forum Sencha Touch 1.x: Q&A
    Replies: 1
    Last Post: 29 Feb 2012, 11:40 AM
  3. Rendering Buttons/Panels
    By J.B in forum Sencha Touch 1.x: Discussion
    Replies: 1
    Last Post: 5 Sep 2010, 5:54 PM
  4. buttons are not like items for panels. why?
    By db77 in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 25 Mar 2008, 12:48 AM
  5. Dragging Panels - Offset between drag container and actual object
    By alamandrax in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 25 Nov 2007, 3:07 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •