We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 24714
    • 19 Posts
    Sorry if i ve chosen the wrong place to right this =)

    I made, custom grid in my CMP, the point is - when i minimize left tree - my grid doesn’t automatically resize (same behavior for the settings page btw.) but when i manuall try to change row width, the whole grid "jumps" to 100% width of the screen.

    So the question is ... is there any possibility of the automatic resize =)

    SOrry dor bad english, but this issue is hard to explain, just try your settings page in manager - minimize the tree on the left - and you will understand what i m talking about =)
    • How do you add your component to the page ?
        • 24714
        • 19 Posts
        same way as in doodles tutorial, the problem isn’t in my CMP,

        do the following please first =)

        modx manager->top menu -> system -> settings

        minimize the tree in the left

        resize the grid
        • That’s why i asked, the doodle example does not use the right method to add components to the page using extjs layout border.

          Instead of using MODx.load(), try the following:

          content = Ext.getCmp("modx-content");
          
          var YourComponent = new MODx.YourCompoent();
          content.removeAll();
          content.add(YourComponent );
          content.doLayout();
          


          Now, in don’t remember well, but old Doodle used a landing div of your choice to rendrer your CMP (renderTo: ’your_div’). Since the content is directly handled by the main layout, you have to remove those if you use the above method.
            • 24714
            • 19 Posts
            haven’t tried yet, on the way...

            still that means, that core settings grid also rendered in the "not right" way ??
            • Quote from: Redjik at May 24, 2011, 08:01 PM

              haven’t tried yet, on the way...

              still that means, that core settings grid also rendered in the "not right" way ??

              I don’t really like to talk about the "right way" or else but in this case I do think that they have not taken the simplest way to use Ext capabilities.

              When using a Viewport or a border layout, you don’t need to render each elements in a descendant div, plus it anihilate Ext capabilities to handle resize events properly.
              That’s what keeping the manager’s grids to resize properly and in the next to come 2.1, that’s what causing the scrollbar to cut all panels if they are not within the main content view.
              And since the manager use some javascript positioning, there is no possibility to fix it with CSS.

              • I have not looked at doodles since the beta days, I would have to wonder if it is outdated with the hundreds of changes which have taken place since the year before last.

                Quote from: Redjik at May 24, 2011, 04:34 PM

                same way as in doodles tutorial, the problem isn’t in my CMP,
                  Get your copy of MODX Revolution Building the Web Your Way http://www.sanitypress.com/books/modx-revolution-building-the-web-your-way.html

                  Check out my MODX || xPDO resources here: http://www.shawnwilkerson.com
                • It is not outdated. Components will work the doodle way.

                  The thing is that i overuse the screen separator introduced in Windows 7 , and at home i have a dual screen configuration.

                  With those two case, i’ve noticed that the main content of the MODx manager did not resize correctly since Revo’s birth.
                  It may be not THAT important, but it bother me.

                  When i look at the WP admin, all the components are fluid and resize properly, it give a more finished feeling of the UI.
                  Now, i can understand that other don’t care about this as long as the Admin do work.

                  The method posted above has been taken from the Ext documention on Layout Border.
                  Basically, if you want, you can use this method of the doodle one, they both allow Ext components to be loaded.
                  But Doodle’s based components are not going to be resized properly.
                    • 24714
                    • 19 Posts
                    quite agree - it is not outdated but it consider some correction - code sometimes a mess,
                    i made this tutorial 3 times to really understand every line and do some optimisations =) (php part, still workin on JS part =)))
                      • 24714
                      • 19 Posts
                      well, everything works fine except ...=)

                      autoResize turns on only after the first manual resize, untill this - the same glitches...