<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>Streamlined: Major Streamlined::UI Refactoring</title>
    <link>http://streamlinedframework.org/articles/2007/07/27/major-streamlined-ui-refactoring</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>Stop banging rocks together and build something</description>
    <item>
      <title>Major Streamlined::UI Refactoring</title>
      <description>&lt;p&gt;In the course of &lt;a href="http://trac.streamlinedframework.org/ticket/82"&gt;fixing a bug&lt;/a&gt;, I bit off of significant refactoring I have wanted to do for a while. Instead of saying this:&lt;/p&gt;
&lt;pre&gt;
# old way 
class PoetUI &amp;amp;lt; Streamlined::UI
  # declarative settings
end
&lt;/pre&gt;
&lt;p&gt;You can now say this:&lt;/p&gt;
&lt;pre&gt;
# new way
Streamlined.ui_for(Poet) do
  # declarative settings
end
&lt;/pre&gt;
&lt;p&gt;The new syntax is more testable, since it does not rely on singleton methods and inheritance. It also makes it much easier to break the default 1-1 relationship between models and ui instances.
The old syntax is still supported, via a bit of method_missing trickery. But I am sure there are some breakages, and I would like to deprecate the old syntax over time. Kick the tires and let me know if you have any problems.&lt;/p&gt;</description>
      <pubDate>Fri, 27 Jul 2007 18:35:22 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:f01444bc-737d-4fcf-852e-5be0fd5ca304</guid>
      <author>Stu</author>
      <link>http://streamlinedframework.org/articles/2007/07/27/major-streamlined-ui-refactoring</link>
      <category>Features</category>
      <category>Fixes</category>
      <trackback:ping>http://streamlinedframework.org/articles/trackback/143</trackback:ping>
    </item>
  </channel>
</rss>
