layout/xul/grid/examples/jumpygrid.xul

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/layout/xul/grid/examples/jumpygrid.xul	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,82 @@
     1.4 +<?xml version="1.0"?> 
     1.5 +<!-- This Source Code Form is subject to the terms of the Mozilla Public
     1.6 +   - License, v. 2.0. If a copy of the MPL was not distributed with this
     1.7 +   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
     1.8 +
     1.9 +
    1.10 +<?xml-stylesheet href="chrome://global/skin/" type="text/css"?> 
    1.11 +<?xml-stylesheet href="gridsample.css" type="text/css"?> 
    1.12 +
    1.13 +<!DOCTYPE window> 
    1.14 +
    1.15 +
    1.16 +<window orient="vertical" style="border: 2px solid green"
    1.17 +        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> 
    1.18 +
    1.19 +    <script>
    1.20 +	  function flip(child)
    1.21 +	  {
    1.22 +	    var jump = child.getAttribute("jumpy");
    1.23 +		if (jump != "true")
    1.24 +		  child.setAttribute("jumpy","true");
    1.25 +		else
    1.26 + 		  child.setAttribute("jumpy","false");
    1.27 +	  }
    1.28 +
    1.29 +	</script>
    1.30 +    <hbox>
    1.31 +		<grid style="border: 2px solid yellow;">
    1.32 +		   <columns>
    1.33 +		   </columns>
    1.34 +
    1.35 +		   <rows>
    1.36 +			 <row>
    1.37 +			   <button label="button" class="jumpy"/>
    1.38 +			   <button label="button" class="jumpy"/>
    1.39 +			   <button label="button" class="jumpy"/>
    1.40 +			   <button label="button" class="jumpy"/>
    1.41 +			   <button label="button" class="jumpy"/>
    1.42 +			 </row>
    1.43 +			 <row>
    1.44 +			   <button label="button" class="jumpy"/>
    1.45 +			   <button label="button" class="jumpy"/>
    1.46 +			   <button label="button" class="jumpy"/>
    1.47 +			   <button label="button" class="jumpy"/>
    1.48 +			   <button label="button" class="jumpy"/>
    1.49 +			 </row>
    1.50 +			 <row>
    1.51 +			   <button label="button" class="jumpy"/>
    1.52 +			   <button label="button" class="jumpy"/>
    1.53 +			   <button label="button" class="jumpy"/>
    1.54 +			   <button label="button" class="jumpy"/>
    1.55 +			   <button label="button" class="jumpy"/>
    1.56 +			 </row>
    1.57 +			 <row>
    1.58 +			   <button label="button" class="jumpy"/>
    1.59 +			   <button label="button" class="jumpy"/>
    1.60 +			   <button label="button" class="jumpy"/>
    1.61 +			   <button label="button" class="jumpy"/>
    1.62 +			   <button label="button" class="jumpy"/>
    1.63 +			 </row>
    1.64 +			 <row>
    1.65 +			   <button label="button" class="jumpy"/>
    1.66 +			   <button label="button" class="jumpy"/>
    1.67 +			   <button label="button" class="jumpy"/>
    1.68 +			   <button label="button" class="jumpy"/>
    1.69 +			   <button label="button" class="jumpy"/>
    1.70 +			 </row>
    1.71 +			 <row>
    1.72 +			   <button label="button" class="jumpy"/>
    1.73 +			   <button label="button" class="jumpy"/>
    1.74 +			   <button label="button" class="jumpy"/>
    1.75 +			   <button label="button" class="jumpy"/>
    1.76 +			   <button label="button" class="jumpy"/>
    1.77 +			 </row>
    1.78 +
    1.79 +		   </rows>
    1.80 +		</grid>
    1.81 +		<spacer style="border: 2px solid white;" flex="1"/>
    1.82 +    </hbox>
    1.83 +	<spacer style="border: 2px solid white;" flex="1"/>
    1.84 +
    1.85 +</window>

mercurial