New revs

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: New revs
« Reply #990, on September 9th, 2011, 04:34 PM »
rev 990
(22 files, 19kb)

* Took a chance and replaced all sSessionVar/sSessionId variables from the JS code with globals. Considering that just like in SMF, the session ID is already on every page (because of the header toggler), it won't make a difference security-wise, it'll just be shorter. Less bandwidth use means more love. (BoardIndex.php, Class-Editor.php, ManageMedia2.php, TEMPLATES: BoardIndex, Display, index, ManageBans, ManageBoards, ManageMaintenance, ManageMembergroups, ManageNews, ManagePaid, ManagePermissions, MessageIndex, PersonalMessage, Profile, SCRIPTS: editor, pm, post, script, suggest, topic)
Re: New revs
« Reply #991, on September 9th, 2011, 11:06 PM »
rev 991
(22 files +2, 28kb)

- Removed entities_convert option from Media area, and related code. We're UTF-only now, why would we use entities? (install.sql, Aeva-Subs-Vital.php, ManageMedia.php, ManageMedia.language.php, Media.language.php)

* Renamed aeva_utf2entities() function to aeva_string(), because even though we no longer convert entities, it still does some good things. For now. (Aeva-Foxy.php, Aeva-Gallery.php, Aeva-Gallery2.php, Aeva-Subs-Vital.php, ManageMedia.php)

! Fixed 'unlinks' in message index and unread posts/replies. (MessageIndex.php, Unread.php, UnreadReplies.php, MessageIndex.template.php, Recent.template.php)

! Fixed message index always showing page 1 in pretty URL mode. (QueryString.php)

! Security file checks would show error messages twice. (Subs.php)

! Event delayer was incorrectly removed if empty (e.g. board index). (Subs.php)

! SMF bug: incorrect link in 'href' member of the topic array. (Unread.php, UnreadReplies.php)

! Long URLs would break the layout in the error log... Cut these strings after 80 chars. Maybe I should simply insert a soft hyphen... (Errors.template.php)

+ Added IE9 and IE10 workarounds to the Warm skin. With a funny story in the IE9 one... (Warm/index.ie9.css, Warm/index.ie10.css)

* Micro-optimizations. (ManageMaintenance.php, Subs-Members.php, Subs-Post.php, Subs-PrettyUrls.php)
Re: New revs
« Reply #992, on September 10th, 2011, 06:41 PM »
rev 992
(1 file, 8kb)

+ Implemented new possible positions for loadLayer(): 'before', 'after', 'replace', 'erase', 'firstchild' and 'lastchild'. Manipulating arrays through references is fun, I need to do that more often. Check out the comments in the source code for more details. (Load.php)
Re: New revs
« Reply #993, on September 11th, 2011, 05:21 PM »
rev 993
(93 files, how amusing -- 89kb)

* Renamed sub-templates to blocks, and all associated variables etc. Updated related documentation and comments. (93 files, not listing them all!)

- Removed a comment that looked like a failed keystroke, or a work in progress that got forgotten in the process. Since it's security related, I felt I should mention it... (Security.php)
Re: New revs
« Reply #994, on September 12th, 2011, 12:18 AM »
rev 994
(1 file, 9kb)

* Rewrote loadBlock() to allow for different options, not unlike loadLayer(): 'replace' (the original default), 'add' (what used to be the $overwrite parameter), and 'first' (insert at the beginning.) It doesn't take child layers into account yet, as I have yet to decide how I'll handle them. Maybe I should prevent adding blocks to a layer that has child layers... (Load.php)

@ Note: I actually wrote the code to handle replacing blocks in layers that hold a child layer, but it's pretty f*cked up that way... I think I need to sleep on it.
Re: New revs
« Reply #995, on September 12th, 2011, 10:26 PM »
rev 995
(6 files, 15kb)

+ Added proper support for 'replace' in loadBlock(). It's easy enough when a layer only has blocks in it, so the hard part was to keep layers in while deleting the rest. If you want to delete layers as well, just use the new 'erase' parameter instead. It will cancel the rescue mission for layers. (Load.php)

* Updated all loadBlock() calls that provided a boolean parameter, and replaced them with the 'add' param instead. (index.php, Aeva-Gallery.php, Subs-Menu.php)

* Updated documentation on blocks and added a 'left' hint to the Warm and Wine sidebars. (index.template.php, Warm/skin.xml)

* Ensured mods can't replace sidebar elements by mistake. Well, they can still delete the sidebar entirely, but then they know they're doing it wrong. (Load.php)

! Fixed support for multiple hints in skeleton. (Load.php)
Re: New revs
« Reply #996, on September 12th, 2011, 10:47 PM »
rev 996
(1 file, 8kb)

+ Added support for 'before' and 'after' in loadBlock(). That one was quick... It's because I just recycled code eheh. loadBlock('block', 'menu', 'after') will add a block called 'block' right after the main menu block. I'm not sure it's great to be able to specify a target block (instead of just a layer), but I'll think about it. (Load.php)
Re: New revs
« Reply #997, on September 15th, 2011, 01:20 AM »
rev 997
(6 files, 18kb)

! Fixed broken Wireless and XML handling. Basically, their skeletons were erased before it was even created, so Wedge was using default settings for them anyway. Also fixes an SMF bug, where a lot of init code was executed even when templating was already disabled or overridden. (Load.php, Subs.php)

* Renamed the 'main' layer to 'context', to avoid confusing it with the 'main' block. (Load.php, Profile.php, Security.php, Subs.php, index.template.php, Warm/skin.xml)

* Added a few safeguards and fallbacks for the skeleton handling code. Not that it was needed, again, but in some situations it avoids obscure error messages at virtually no cost. (Load.php, Subs.php)

! loadBlock(...'erase') should regenerate the layer list, because it might delete layers without even checking. (Load.php)

! Fixed hideChrome() to always insert a dummy layer at the top when resetting the skeleton array. This makes it possible to add layers before and after the only remaining one. If that's ever needed. (Subs.php)

* Reworked build_skeleton_indexes() to avoid having to use a parameter. Also pestering about the uselessness of array_walk_recursive(). (Load.php, Subs.php)

! skeleton_insert_layer() had an extra parameter that was forgotten from a prior commit, and would make the process fail. Also admitted failure when it comes to the layer update. Although in most cases a rebuild isn't needed, I've found a few places where it is. Rebuilding is thus a tad slower, but more robust. (Load.php)
Re: New revs
« Reply #998, on September 15th, 2011, 02:13 PM »
rev 998
(2 files, 7kb)

* Moved the PM draft saving code up in the code path, so that it doesn't waste time initializing the PM template and menus. The Subs-Menu change is not needed, but I'd like to see if it generates errors in the log. Let's call it an experiment. (PersonalMessage.php, Subs-Menu.php)

! The page index for PM drafts had an incorrect URL (area instead of sa). (PersonalMessage.php)

+ Started added placeholders for menu notices. Or warnings. Or notifications. Or whatever. (PersonalMessage.php)

@ Note: I'm starting a series of a few short commits because I changed files in various areas and I'm still trying to keep these in a logical order.
Re: New revs
« Reply #999, on September 15th, 2011, 02:15 PM »
rev Galaxy Express 999
(5 files, 8kb)

- No need for loadBlock('main')... Uh. That one wasn't in SMF, I don't know where it came from really. (Calendar.php)

! Was a bit too quick to remove $hard_limit from aeva_string() when it's actually used in westr::cut()... (Aeva-Subs-Vital.php)

! Fixed a CSS error generated by the menu JavaScript when hovering a top-level item in non-main menus. (script.js)

! French translation used the third person unlike the first person used in other strings. (Profile.french.php)

- A forgotten comment from a forgotten era. (Profile-Modify.php)
Re: New revs
« Reply #1000, on September 15th, 2011, 02:28 PM »
rev T-1000
(4 files +3, 21kb)

* 1000 R.E.V. shalt be the year of the Apocalypse. Thou shalt brandish thy new logo and adore it. Unless it gets changed again, it goes without saying. What?

* Replacing minilogo.png with the new style logo. Still a work in progress...? (minilogo.png)

+ Added a minilogo with white text for darker backgrounds, notably in Wine. (minilogow.png, index.css)

* Warm makes use of the rarely used @remove tag to replace the minilogo and avoid including the other one in the CSS. I should probably rewrite it to make it easier to simply remove filtered *files* instead of filtered properties... (Warm/index.css)

+ Added media/avatars and media/files folders, for later use by the media code. Gotta start somewhere. (media/*)

- Removed an used $sc global. Should also remove it from dozens of other places... It's gonna be fun. Or not. (Admin.php)

@ FWIW, I was also the one who committed rev 10.000 to the SMF SVN... I like collecting SVN milestones 8-)
Re: New revs
« Reply #1001, on September 15th, 2011, 07:05 PM »
rev 1001
(11 files, 10kb)

- Removed $sc from globals when not actually used in the code. Please note that $context['session_id'] should have the same value in it anyway. (Load.php, ManageMemberOptions.php, ManageServer.php, ManageSettings.php, ModerationCenter.php, PersonalMessage.php, Post.php, Subs-OpenID.php)

+ Added language strings for a fatal error in draft code. (Subs-Post.php, Post.language.php)
Re: New revs
« Reply #1002, on September 16th, 2011, 07:58 PM »
rev 1002
(6 files, 12kb)

! The gradient rule in WeCSS only accepted rgb/rgba data, so added support for #hex values as well. (Class-CSS.php)

* Don't bother showing the favicon code if the forum is already at the root. I think it's the correct way to do it... (index.template.php)

+ Added basic support for CSS-driven notifications inside menus. Only for the main menu right now, though. IE support incoming (like anyone cares.) (Subs.php, index.template.php, index.css)

- Removed a test before loading media settings, that became useless a few weeks ago. (Subs.php)

* Spacinazi. (Subs-Boards.php, MessageIndex.template.php)


@ Now the PM menu will say 'NEW' and the Inbox sub-menu will say the actual number of posts, like in the Admin menu. Is it for the best? (i.e. 'NEW' may mean something to new users, but after a while they may be annoyed that they have to hover the menu before they know how menu new PMs they have...)
Re: New revs
« Reply #1003, on September 16th, 2011, 11:09 PM »
rev 1003
(12 files, 12kb)

! Fixed SMF bug: fixed position of the #new anchor on topics where at least one message is unapproved. (Display.php)

! create_button() was missing a non-breakable space after the actual button when button captions is enabled. (Subs.php)

* Various micro-optimizations, mostly on the display query string and on substr($string, 0, 1) (there's really no reason not to use $string[0] as it's 3 times faster, except in special cases like using these as offsets for array addition -- PHP tends to crash on that. Didn't optimize the lesser called functions. Also, strpos() is faster than substr() on very short strings. (Display.php, Class-DB.php, Class-DBPackages.php, Class-Editor.php, Aeva-Foxy.php, Aeva-Subs-Vital.php, PersonalMessage.php, Profile-Modify.php, Profile-View.php, Subs-Admin.php, SSI.php)
Re: New revs
« Reply #1004, on September 17th, 2011, 10:45 AM »
rev 1004
(11 files +1, 144kb) (only because of the file move.)

+ Moved all templating code from Subs and Load to a new file, Subs-Template.php. I wish I would have done it before I wrote the skeleton system... New file is 50KB+ and as a result, Subs.php is now less than 100KB and Load.php is not far away. Way better for readability. (Subs.php, Load.php, Subs-Template.php)

* Admins know better, so I got rid of the $txt['new'] notification in the admin area and replaced it directly with the error count. (Subs.php)

! Fixed pre-type tags (code/php) from breaking post layout when showing long lines. This was due to not specifying table-layout:fixed on posts, silly me. (sections.css)

! Another benefit of this change is that I was able to get rid of the max-width on code tags. (index.css)

! Fixed backgrounds in message index when topics have sticky/locked/etc icons. Best I can do without a heavier rewrite. (sections.css)

! Fixed gradient filter not showing up for IE8 and IE9 and sub-menus being broken in IE7. I have no idea why it fails when float is to none in IE8 and IE9, and when float is set to right in IE6 and IE7... Well, that's IE isn't it. Why should IE9 be any better. (index.ie*.css)

* Recent post list doesn't need 2-pixel separators between user name and message. Just one is enough. (sections.css)

* Tweaked margins in top menu notifications. (index.css)

* Updated mini-logo with the new logo. Kept the same Helvetica-based font for now... (minilogo.png, minilogow.png)

* Spacinazi. (Subs-PrettyUrls.php)