Path

ez projects / ezyui / forum / general / bug path of ezyui incompati...


BUG path of ezyui incompatible with ezpacker

You need to be logged in to post messages in the forums. New users may register here.

Björn Dieding@xrow.de

Member since:
07 March 2003

Posts: 47

Monday 20 July 2009 6:55:20 pm

rename

http://svn.projects.ez.no/ezyui/trunk/ezyui/design/standard/lib/

to

http://svn.projects.ez.no/ezyui/trunk/ezyui/design/standard/javascript/

This line of the packer breaks my neck.

$packedFiles = eZYuiPacker::packFiles( $scriptFiles, 'javascript/', '.js', $packLevel, $wwwInCacheHash );

If you move it you also don`t need the additional rw rule.

Looking for a new job? http://www.xrow.com/xrow-GmbH/Jobs
Looking for hosting? http://hostingezpublish.com
-----------------------------------------------------------------------------
GMT +01:00 Hannover, Germany
Web: http://www.xrow.com/

Up

Łukasz Serwatka

Member since:
29 September 2004

Posts: 29

Tuesday 21 July 2009 12:14:52 am

I would keep files where are now. As it is more logical to keep it in the lib directory as in the javascript. YUI is not only the JS files, but also CSS, images which are part of default skin for controls. Serving them from javascript directory is a bit weird. This should be fixed in packer IMHO.

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog
Twitter -> @lserwatka
LinkedIn -> http://pl.linkedin.com/in/lukaszserwatka

Up

Björn Dieding@xrow.de

Member since:
07 March 2003

Posts: 47

Tuesday 21 July 2009 3:39:02 pm

In this case we definitly need to fix the packer.

I might supply a patch when I have more time.

Looking for a new job? http://www.xrow.com/xrow-GmbH/Jobs
Looking for hosting? http://hostingezpublish.com
-----------------------------------------------------------------------------
GMT +01:00 Hannover, Germany
Web: http://www.xrow.com/

Up

André R

Member since:
20 August 2005

Posts: 171

Tuesday 21 July 2009 10:28:07 pm

Or we can move scripts to javascript dir, css to stylesheets dir and images to images dir?

--
ar

Up

Björn Dieding@xrow.de

Member since:
07 March 2003

Posts: 47

Thursday 23 July 2009 1:27:05 am

I would not rip it apart... people used top the yui might get confused...

Looking for a new job? http://www.xrow.com/xrow-GmbH/Jobs
Looking for hosting? http://hostingezpublish.com
-----------------------------------------------------------------------------
GMT +01:00 Hannover, Germany
Web: http://www.xrow.com/

Up

André R

Member since:
20 August 2005

Posts: 171

Tuesday 28 July 2009 10:37:39 am

Hi again!

Thanks for fixing a couple of things, however, it would be nice to review your patches before you commit them.
For instance you shouldn't do several things at once in a commit, and the "- added charset parameter to operators" will break any use of the operators that use the last param. Not a big deal as ezyui isn't even at the beta stage and will see some changes, but you really need to discuss this with the other members of the project, so they know about it..

And I'm not convinced the patch for the lib problem is the correct one, it might be better to allow full (design) path if it starts with '/' for instance(see bellow patch), what do you think?

We need to make this as general as possible, just like eZ Publish, so we can't commit workaround code.

Sorry for bringing this up, but as we are a team, we really need to be able to review and discuss, especially patches.

All in sense of better co-operation in future :)





Index: trunk/ezyui/classes/ezyuipacker.php


===================================================================


--- trunk/ezyui/classes/ezyuipacker.php (revision 21)


+++ trunk/ezyui/classes/ezyuipacker.php (working copy)


@@ -256,15 +256,14 @@


            // or is it a relative path


            else


            {


-               $file = $file;


+               // allow path to be outside subpath if it starts with '/'


+               if ( $file[0] === '/' )


+                   $file = ltrim( $file, '/' );


+               else


+                   $file = $subPath . $file;


+


                $triedFiles = array();


                $match = eZTemplateDesignResource::fileMatch( $bases, '', $file, $triedFiles );


-               // Work around many extensions use design.ini[JavaScriptSettings].JavaScriptList but the path is not correct 

-               if ( $match === false )


-               {


-                      $file = $subPath . $file;


-                      $match = eZTemplateDesignResource::fileMatch( $bases, '', $file, $triedFiles );


-               }


                if ( $match === false )


                {


                    eZDebug::writeWarning( "Could not find: $file", __METHOD__ );


--
ar

Up

You need to be logged in to post messages in the forums. New users may register here.