KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tonbeller > wcf > toolbar > PushButtonTag


1 /*
2  * ====================================================================
3  * This software is subject to the terms of the Common Public License
4  * Agreement, available at the following URL:
5  * http://www.opensource.org/licenses/cpl.html .
6  * Copyright (C) 2003-2004 TONBELLER AG.
7  * All Rights Reserved.
8  * You must accept the terms of that agreement to use this software.
9  * ====================================================================
10  *
11  *
12  */

13 package com.tonbeller.wcf.toolbar;
14
15 import com.tonbeller.wcf.controller.RequestContext;
16
17
18 /**
19  * Created on 06.01.2003
20  *
21  * @author av
22  */

23 public class PushButtonTag extends ToolButtonTag {
24
25   private boolean pressed = false;
26   
27   /**
28    * @see com.tonbeller.wcf.toolbar.ToolButtonTag#getToolButtonModel()
29    */

30   protected ToolButtonModel getToolButtonModel(RequestContext context) {
31
32     PushButtonModel pbm = new PushButtonModel();
33     pbm.setPressed(context, isPressed());
34     return pbm;
35   }
36
37   /**
38    * Returns the pressed.
39    * @return boolean
40    */

41   public boolean isPressed() {
42     return pressed;
43   }
44
45   /**
46    * Sets the pressed.
47    * @param pressed The pressed to set
48    */

49   public void setPressed(boolean pressed) {
50     this.pressed = pressed;
51   }
52
53 }
54
Popular Tags