New revs

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: New revs
« Reply #690, on March 29th, 2011, 10:39 PM »
rev 672
(17 files, 19kb)

+ Added support for the $language variable in cached CSS files. Will be useful once I move the 'New' icon to CSS. (Subs-Cache.php)
! Make sure the index template is loaded before we add the RSS sidebar block. It would crash on $simpleActions otherwise. (index.php)
* $context['is_ajax'] isn't the only case where the chrome should be hidden, so I introduced a $context['hide_chrome'] variable instead, which is also set to true automatically in Ajax mode. (QueryString.php, Subs.php, Errors.template.php)
+ Added a new function, hideChrome(), which ensures Wedge will avoid showing the top and sidebar templates. You may also add a parameter that will list the main template layers you wish to use. Haven't tested most of the changes, but it should be fine. (CoppaForm.php, Load.php, ModerationCenter.php, Packages.php, Printpage.php, Reports.php, Spellcheck.php, Subs.php, VerificationCode.php)
! Fixed a cases where resetting the template layers was already done, something like that. (Help.php)
* Spacinazi. (CoppaForm.php, ManageErrors.php, Printpage.php, Subs-Cache.php, Admin.template.php, Errors.template.php, Search.template.php)

@ Note: $txt['image_lang'] isn't defined in our languages, but is used in the code. Should we remove it, or is it used for some specific languages? (Load.php)
@ Also: Pete, can you look into the hideChrome() occurrences? I didn't realize there were so many template resets... To think that most of them were broken in the previous rev, and none of us noticed it! :^^;:
Re: New revs
« Reply #691, on March 29th, 2011, 10:45 PM »
As often, I'm trying to commit big releases in several chunks, for readability reasons. I still need to fix Wine (I'm currently moving it to the root, 90% finished, took me many hours to do the move, oddly.)

rev 673
(9 files, 17kb)

* Renamed some classes in special templates to avoid confusing them with classes in the main style. Also made the names shorter because WAP cellphones usually have limited bandwidth... Saving money is good. (Reports.template.php, Wireless.template.php, report.css, wireless.css)
! News fader's icon didn't match the starting fold state. (BoardIndex.template.php)
- Removed .header class, which breaks the layout, but it'll be fixed in the next commit (big stuff coming.) (BoardIndex.template.php)
- Removed #menu_container class, as #navi already acted as such. Also removed .forumtitle class, as there's only one h1 tag in the headers. Styling coming in the next commit. (index.template.php)
* Replaced alt="!" crap with actual IDs. Styling coming..you know the drill. (GenericMenu.template.php, Pastel/index.css)
- Sometimes, some obscure, rarely used stuff is too precisely styled. Why bother? (member.css)
Re: New revs
« Reply #692, on March 31st, 2011, 04:44 PM »
rev 674
(36 files + 4, 71kb - mostly maintenance stuff but might be worth a look, if only at the changelog.)

* Harmonized file endings in the Sources folder, and other very minor spacing or logic changes. Oops, I forgot the closing PHP tag on a few of the classes I created... (Class-CSS.php, Class-JSMin.php, Class-Packer.php, ManageMaintenance.php, ManageMembers.php, ManageNews.php, ManageServer.php, PostModeration.php, PrettyUrls-Filters.php, Profile.php, Security.php, Subs-Captcha.php, Subs-Post.php, Subs-PrettyUrls.php, Subs.php)
* Reduced filesize of Wedge mini-logo and symbol, and moved original 32-bit versions to the other/images folder. (minilogo.png, wedgesight.png, wedgeship.png, minilogo-256.png)
* Every nerd knows that math trumps sex. (index.php, SSI.php)
* Saved a whopping two bytes per page load. What? (index.template.php)
* A detail in the French translation. Details annoy me enough to fix them. (index.french.php)
* Board manager had inverted cat and title header types. (ManageBoards.template.php)
- Removed debug parameter in updateSettings (unused.) (Subs.php)
- We don't see a reason to initialize rand_seed separately with microtime() instead of mt_rand. (Subs.php)
- No need for an extra cookie test when showing the newsfader. (BoardIndex.template.php)
- Removing the ONLY remaining occurrence of the titlebg2 class in Wedge. (Calendar.template.php)
- Removing last occurrences of tborder and bordercolor classes. They're remnants from SMF's Core theme, mainly. Also fixed related indentation. (TEMPLATES: Display, Login, Memberlist, MessageIndex, Packages, PersonalMessage, Profile, Recent, Register, Reminder, SplitTopics, Themes, admin.css)
Re: New revs
« Reply #693, on March 31st, 2011, 11:33 PM »
rev 675
(many files, big size. Didn't check it exactly, as I was busy fighting tree conflicts.)

* Switched Warm for Wine as new default styling. Wine is now a replace type, and Warm is an add type. Removed many useless default props for regular divs. Nested a few more declarations for readability. Got rid of titlebg2, tborder and other useless styles. (styles/*)
+ Added support for the "for" keyword in styling blocks. For instance <block name="cat" for="ie6,ie7"> should generate markup exclusive to IE6 and IE7. (Subs-Cache.php)
* Core Features page should show an underline for active feature links. (admin.css)
* Styling pick page in the profile area could use better header hierarchy. (Themes.template.php)
* Improved board list in Manage Board area, by showing a dotted bottom border instead of a complete solid border. (admin.css)
* IE6 doesn't need PNG fixes for the header area's reddish zones. A simple solid background saves time. (ie6.css)
* Re-implemented PNG fixes for windowbg/windowbg2, though. It's not that slow to apply, and it looks slightly better. Added instructions to disable it if you like. (settings.xml, ie6.css)
! Fixed a very small bright line that always showed up below the main menu in Wine. Finally got the bugger. (ie6.css)
! Fixed various details in the Pastel styling. Still needs a LOT of fixing. (Pastel/ie6.css, Pastel/index.css)
! Fixed double float margin in IE6 for upshrinks. (sections.css)
- Webkit didn't like the catbg/titlebg forced height. (webkit.css)
Re: New revs
« Reply #694, on April 1st, 2011, 11:42 PM »
Quite satisfied with tonight's work... Quick, barely buggy on first try, and all in all interesting -- notably the fact that WeCSS now supports retrieving file sizes dynamically. (Maybe I should use $images instead of $images_dir and transform the URL on the fly, though... But the current solution is, err... Safer?)

rev 676
(14 files, 18kb)

+ Renamed wecss_func class to wecss_color, and implemented wecss_func class with two new functions. width(url) and height(url) will return the dimensions of any image. Make sure to use the _dir variable variations for best results. ($images_dir instead of $images, etc.) (Class-CSS.php, Subs-Cache.php)
+ Added $language_dir, $images_dir and $theme_dir variables, for the above. Also fixed $language to actually work.
+ Added westr::safe(), which is just like westr::htmlspecialchars() but slightly faster (and simpler.)
* Turned language-specific new.gif into a base64 icon. YES. (Profile-Modify.php, SSI.php, BoardIndex.template.php, MessageIndex.template.php, PersonalMessage.template.php, Post.template.php, Recent.template.php, sections.css)
! $user_info['url'] (used in the language switcher) didn't have the proper current URL if inside a board. Hopefully this weird fix won't cause trouble. (Load.php)
! Don't need to recalculate $css_vars['$here'] on every file addition... Only the last one is needed. (Subs-Cache.php)
- Don't bother with IE6 emulation of windowbg backgrounds, because it doesn't seem to work on tr tags, and my patience is limited. (ie6.css)
Re: New revs
« Reply #695, on April 2nd, 2011, 08:15 PM »
The more time I spend on Pastel, the more depressed I am... Hence its new name :P

rev 677
(12 files + 7 modified, 45kb)

* Moved feed icon to CSS. (BoardIndex.template.php, index.template.php, index.css)
* Moved Pastel to under Warm, renamed it to Wuthering and fixed it. Not perfect, and not optimized... But I don't really care at this point. (Pastel/*, Warm/Wuthering/*)
! Fixed CSS variable declarations with mismatched opening or ending double quotes. (Class-CSS.php)
* Renamed "News" item to "In the news" in the French version. Makes more sense. (index.french.php)
* Replaced the semi-colon next to "News" with an arrow. (index.template.php, index.css, sections.css)
Re: New revs
« Reply #696, on April 3rd, 2011, 01:30 AM »
rev 678
(21 files +3, 22kb)

* Replaced all helptopics.gif occurrences with CSS. Again: YAY. (sections.css, other/ssi_examples.php, Modlog.php, Admin.english.php, Admin.french.php, TEMPLATES: Admin, Errors, GenericMenu, Login, ManageMaintenance, ManageNews, ManagePermissions, ManageSearch, ModerationCenter, Packages, Profile, Themes)
! Fixin' bad filters in Warm. Cancelled the fixes in Wuthering because they get inherited anyway. (Warm/ie*.css)
! Fixin' some odd stuff in IE6 admin layout. (ie6.css)
Re: New revs
« Reply #697, on April 3rd, 2011, 10:59 AM »
rev 679
(7 files, 11kb)

! A few of the help text links were being hidden by the help icon. (Admin.english.php, Admin.french.php, Login.template.php, Packages.template.php, Profile.template.php, Register.template.php)
* Indenazi. (Profile.template.php, sections.css)
Re: New revs
« Reply #698, on April 3rd, 2011, 11:08 PM »
rev 680
(7 files, 9kb)

! Fixed sidebar width in Chrome/Safari, due to a minor glitch in the var parsing regex. (Class-CSS.php)
! Fixed horizontal matching of dt/dd tags not working in IE6/IE7 due to a bug with clear: both and floated elements. Fixed through trial and error... (ie6.css, ie7.css, index.css)
! Fixed main content (next to sidebar) width in most browsers, due to an earlier fix for IE (what else?). (index.css)
- dl.settings_title is never used anywhere. (index.css)
- Can't find #ip_list anywhere either. (rtl.css)
- And .header... I think I removed the last one this week. (webkit.css)
* Modified Warm to make the sidebar blend in with the background, and have a single vertical rule separate it from the main content. (Warm/index.css)
Re: New revs
« Reply #699, on April 3rd, 2011, 11:46 PM »Last edited on April 6th, 2011, 07:24 PM by Nao/Gilles
rev 681

* Wuthering is back to being a root subfolder. Saves 700 bytes off the gzipped CSS file, and is slightly simpler. (Wuthering/*)
Re: New revs
« Reply #700, on April 6th, 2011, 07:24 PM »
Okay... There it is! :)
It's got a bug every ten lines, but it doesn't crash (at least not superficially.)
A note for testers: take the file /other/db_aeva.php, move it to the root, and run it from your browser. It should safely add all of the needed tables and table fields for you, just like Aeva Media's installer. Eventually, this file will be integrated into install.php, obviously.

rev 682
(98 files +197 files, 3.0 megabytes... W00t!!! :lol:)

+ Added Aeva Media. Now we're talking. (index.php, media/*, other/db_aeva.php, other/images/sprite-32bit.png, other/install.sql, Admin.php, Class-Editor.php, Load.php, ManagePermissions.php, Profile.php, Subs.php, Themes/default/aeva/*, images/aeva/*, images/bbc/sprite.png, Media.template.php, ManageMedia.template.php, editor.js, media.js, media-admin.js, uploader.js, index.css, media.css, up.css, LANGUAGES: Admin, Errors, Help, index, ManageMedia, ManagePermissions, Media, Post, Who)
* Renamed loadSubTemplate() to execSubTemplate(), and showSubTemplate() to loadSubTemplate(). Makes more sense. (Activate.php, Admin.php, Announce.php, BoardIndex.php, Calendar.php, CoppaForm.php, Credits.php, Display.php, Errors.php, Findmember.php, Groups.php, Help.php, Jseditor.php, JSModify.php, Load.php, Login.php, Login2.php, ManageAttachments.php, ManageBans.php, ManageCalendar.php, ManageErrors.php, ManageMail.php, ManageMaintenance.php, ManageMembergroups.php, ManageMembers.php, ManageNews.php, ManagePaid.php, ManagePermissions.php, ManagePosts.php, ManageRegistration.php, ManageScheduledTasks.php, ManageSearch.php, ManageSearchEngines.php, ManageServer.php, ManageSettings.php, ManageSmileys.php, Memberlist.php, MessageIndex.php, ModerationCenter.php, Modlog.php, Notify.php, PackageGet.php, Packages.php, PersonalMessage.php, Post.php, PostModeration.php, Profile-Actions.php, Profile-Modify.php, Profile-View.php, Profile.php, QueryString.php, QuoteFast.php, Register.php, Reminder.php, RepairBoards.php, Reports.php, Reporttm.php, Search2.php, Security.php, SendTopic.php, Spellcheck.php, SplitTopics.php, Stats.php, Subs-Auth.php, Subs-Menu.php, Subs-Package.php, Subs.php, Suggest.php, Themes.php, Unread.php, Unreadreplies.php, VerificationCode.php, Xmlhttp.php)
! Potential undefined index in browser detection code. (Load.php)
! Fixed infinite loop when providing a CSS file with a wrong path. (Subs-Cache.php)
! If asking for a full HTML5 tag along with the CSS file, the wrong parameter was used (src instead of href). (Subs-Cache.php)
! Small icon fix in menu code, and a temporary fix for Aeva Media icons. This one needs to go! (Subs-Menu.php)
! Fixed $here position to be dependent on the current file's position, rather than the final file, when several files were being requested at once. (Subs-Cache.php)
! Saving one's personal options for the first time wouldn't refresh the options page with the new settings. (Profile-Modify.php)
! Prevent user from moving popup window in source browser (error log). (ManageErrors.php, script.js)
* Moving Unknown's credit to the SMF2 area and other minor details. (Credits.php, Who.english.php, Who.french.php, Who.template.php)
* Use hideChrome instead of the old method. (ViewSMFile.php)

@ Need to make sure including Exifer is okay. (GPL license)
@ My biggest commit ever (in the past, AND in the future I hope)... This is madness.
Re: New revs
« Reply #701, on April 7th, 2011, 11:10 AM »
rev 683 -- another cool commit IMHO :)
(10 files, 22kb)

+ Added support for complex blocks. (Load.php, QueryString.php, Subs-Cache.php, index.template.php, settings.xml)
+ Finished implementing Aeva Media's install-both.xml file. Used the opportunity to also protect PMs with only a video in them, and add HTML5's video and audio tags to the whitelist. (JSModify.php, Post2.php, Subs-BBC.php, Who.php)
! Fixed a silly undefined index error. (Profile-Modify.php)

@ To do: add support for complex blocks in stylings other than Wine. Move default block setup to index.template.php's template_init(), so that it can effectively be set up by the theme itself.
Re: New revs
« Reply #702, on April 7th, 2011, 12:13 PM »
rev 684
(2 files, 7kb)

! Fixed undefined index errors anywhere Aeva was in action. $context['utf8'] no longer exists in Wedge, since we're always in UTF mode... Also removed a corresponding helper function, and a few 'u' modifiers that really didn't make sense at all. (Aeva-Embed.php, Aeva-Subs-Vital.php)
Re: New revs
« Reply #703, on April 7th, 2011, 07:03 PM »
rev 685
(17 files, 60kb)

! Block matching would crash on the front page, for a reason too obscure to me (and thus, probably to you too.) Replaced main regex to use atomic grouping. Although it shouldn't be of any use, it has proven its value in the similarly weird Goddess of All Regex in Aeva-Embed.php. Also made sure that identical nested blocks don't collide with each other. And finally, array_shift() shouldn't be called on an empty array, even if it doesn't generate an error. Now, who reads these changelogs anyway? Fixed some stuff buddies, and it works better now, that's all ya need to know. (Subs.php)
* Since 99% of all template_button_strip calls use a "right" parameter, set it to be the default. And seriously, the default actually generates a floattop class, which doesn't exist. SMF glitch! (Media.template.php, Display.template.php, index.template.php)
! Fixed loadLanguage calling for Aeva files instead of Media. (Aeva-Embed.php, Aeva-Foxy.php, ManageMedia3.php, Subs-Media.php
! Other aeva/media fixes, and removed debug code. (Aeva-Gallery.php, Aeva-Gallery2.php, LANGUAGES: ManageMedia, Media)
! Fixed rich editor to work in the Media area. (Subs-Media.php)
* Moved output buffer post-processing functions from the QueryString file to Subs, at least temporarily. (QueryString.php, Subs.php)
! Minor glitch in definition lists. Whatever. (index.css, sections.css)

@ Note: button strips need to be context_menus, actually.
Re: New revs
« Reply #704, on April 8th, 2011, 01:33 AM »
rev 686
(3 files, 11kb) (small, but took my evening away... >_<)

! Rewrote the block system (again!) to fix more crashes and allow for better handling of complex nested blocks with or without parameters, and define the default entries in the index template, rather than the Load file. Also documented some of the features. (Load.php, Subs.php, index.template.php)
* Moved sidebar and main content into blocks, and used the block system's browser detection feature to deal with IE6/7. (index.template.php)

NB: Here's what I changed in the block detection code, if you're interested...
  [^<] gets a + to save some memory by handling multiple non-< characters at once.
  Allow nested blocks within a block search, as long as it doesn't have the same block type. It doesn't work without the \\1. Will need further tests to understand why.
  Use the greedy setting to minimize memory consumption on big pages.
  Used a similar regex change on the <if> block searches.
  Rearranged variable search code in a way that makes more sense (and actually works.)