Move all the other buttons to spark components, and resize the reverse ones to fit
authorAndy Allan <andy@gravitystorm.co.uk>
Tue, 13 Sep 2011 14:00:36 +0000 (15:00 +0100)
committerAndy Allan <andy@gravitystorm.co.uk>
Tue, 13 Sep 2011 14:00:36 +0000 (15:00 +0100)
net/systemeD/potlatch2/Toolbox.mxml

index 504bba8d93b05646c7deb76e9ab2a010fe9dd962..38a4fc893d3c61c16359533fb404fa4bac00bf51 100644 (file)
 
                <!-- Top row -->
 
-               <mx:Button icon="@Embed('../../../embedded/delete.svg')"
+               <s:Button icon="@Embed('../../../embedded/delete.svg')"
                        click='doDelete();' 
                        enabled="{canDo('delete')}" 
                        alpha="{getAlpha('delete')}" 
                        toolTip="{deleteToolTipText()}" 
-                       width="28" height="28" textAlign="left" y="4" x="6" paddingLeft="6" paddingRight="0" />
+                       width="28" height="28" y="4" x="6" />
 
-               <mx:HBox id="reverseButton" width="28" height="28" y="4" x="36" borderStyle="solid" cornerRadius="4"
-                         click="reverseClicked();" horizontalAlign="center" verticalAlign="middle" toolTip="Reverse direction (V)">
+               <mx:HBox id="reverseButton" width="28" height="28" y="4" x="36" borderStyle="none"
+                          horizontalAlign="center" verticalAlign="middle" toolTip="Reverse direction (V)">
             <mx:ViewStack id="rotateButtonStack" creationPolicy="all">
                 <mx:HBox id="arrowBoxWrapper">
-                                       <s:NavigatorContent width="22" height="22">
-                                               <s:Button id="arrow" icon="{Arrow}" width="22" height="22" alpha="{getAlpha('reverseDirection')}" />
+                                       <s:NavigatorContent width="28" height="28">
+                                               <s:Button id="arrow" icon="{Arrow}" width="28" height="28" alpha="{getAlpha('reverseDirection')}" click="reverseClicked();"/>
                                        </s:NavigatorContent>
                 </mx:HBox>
                 <mx:HBox id="clockwiseBox" horizontalAlign="center" verticalAlign="middle">
-                    <mx:Image id="clockwise" source="@Embed('../../../embedded/clockwise.svg')"
+                    <s:Button id="clockwise" icon="@Embed('../../../embedded/clockwise.svg')"
                         alpha="{getAlpha('reverseDirection')}"
-                        width="22" height="22" x="2" y="2"/>
+                        width="28" height="28" click="reverseClicked();" />
                 </mx:HBox>
                 <mx:HBox id="antiClockwiseBox" horizontalAlign="center" verticalAlign="middle">
-                    <mx:Image id="anticlockwise" source="@Embed('../../../embedded/anti-clockwise.svg')"
-                        click='doReverseDirection();'
+                    <s:Button id="anticlockwise" icon="@Embed('../../../embedded/anti-clockwise.svg')"
                         enabled="{canDo('reverseDirection')}"
                         alpha="{getAlpha('reverseDirection')}"
-                        width="22" height="22" x="2" y="2"/>
+                        width="28" height="28" click="reverseClicked();" />
                 </mx:HBox>
             </mx:ViewStack>
         </mx:HBox>
-               <mx:Button icon="@Embed('../../../embedded/cut.svg')" 
+               <s:Button icon="@Embed('../../../embedded/cut.svg')"
                        id="splitButton"
                        click='doSplit();'
                        enabled="{canDo('split')}" 
                        alpha="{getAlpha('split')}" 
                        toolTip="Split way (X)" 
-                       width="28" height="28" textAlign="left" y="4" x="66" paddingLeft="8" paddingRight="0" />
-               <mx:Button icon="@Embed('../../../embedded/merge.svg')" 
+                       width="28" height="28" y="4" x="66" />
+               <s:Button icon="@Embed('../../../embedded/merge.svg')"
                        id="mergeButton"
                        click='doMerge();'
                        enabled="{canDo('merge')}" 
                        alpha="{getAlpha('merge')}" 
                        toolTip="Merge ways" 
-                       width="28" height="28" textAlign="left" y="4" x="96" paddingLeft="3" paddingRight="0" />
+                       width="28" height="28" y="4" x="96" />
 
                <!-- Second row -->
 
-               <mx:Button icon="@Embed('../../../embedded/straighten.svg')" 
+               <s:Button icon="@Embed('../../../embedded/straighten.svg')"
                        id="straightenButton"
                        click='doStraighten();' 
                        enabled="{canDo('straighten')}" 
                        alpha="{getAlpha('straighten')}" 
                        toolTip="Straighten way" 
-                       width="28" height="28" textAlign="left" y="34" x="6" paddingLeft="5" paddingRight="0" />
-               <mx:Button icon="@Embed('../../../embedded/circle.svg')" 
+                       width="28" height="28" y="34" x="6" />
+               <s:Button icon="@Embed('../../../embedded/circle.svg')"
                        id="circulariseButton"
                        click='doCircularise();' 
                        enabled="{canDo('circularise')}" 
                        alpha="{getAlpha('circularise')}" 
                        toolTip="Make circular" 
-                       width="28" height="28" textAlign="left" y="34" x="36" paddingLeft="4" paddingRight="0" />
-               <mx:Button icon="@Embed('../../../embedded/quadrilateralise.svg')" 
+                       width="28" height="28" y="34" x="36" />
+               <s:Button icon="@Embed('../../../embedded/quadrilateralise.svg')"
                        id="quadrilateraliseButton"
                        click='doQuadrilateralise();' 
                        enabled="{canDo('quadrilateralise')}" 
                        alpha="{getAlpha('quadrilateralise')}" 
                        toolTip="Make right-angled (Q)"
-                       width="28" height="28" textAlign="left" y="34" x="66" paddingLeft="6" paddingRight="0" />
-               <mx:Button icon="@Embed('../../../embedded/parallel.svg')" 
+                       width="28" height="28" y="34" x="66" />
+               <s:Button icon="@Embed('../../../embedded/parallel.svg')"
                        id="parralleliseButton"
                        click='doParallelise();' 
                        enabled="{canDo('parallelise')}" 
                        alpha="{getAlpha('parallelise')}" 
                        toolTip="Create parallel way (P)" 
-                       width="28" height="28" textAlign="left" y="34" x="96" paddingLeft="8" paddingRight="0" />
+                       width="28" height="28" y="34" x="96" />
 
        <fx:Script><![CDATA[