1 /* 2 * Copyright (C) Azureus Software, Inc, All Rights Reserved. 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation; either version 2 of the License, or 7 * (at your option) any later version. 8 * 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details ( see the LICENSE file ). 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with this program; if not, write to the Free Software 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 */ 18 19 package com.aelitis.azureus.ui.common; 20 21 import org.gudy.azureus2.plugins.ui.toolbar.UIToolBarActivationListener; 22 import org.gudy.azureus2.plugins.ui.toolbar.UIToolBarItem; 23 24 public interface ToolBarItem 25 extends UIToolBarItem 26 { 27 public static interface ToolBarItemListener 28 { uiFieldChanged(ToolBarItem item)29 public void uiFieldChanged(ToolBarItem item); 30 triggerToolBarItem(ToolBarItem item, long activationType, Object datasource)31 public boolean triggerToolBarItem(ToolBarItem item, long activationType, 32 Object datasource); 33 } 34 triggerToolBarItem(long activationType, Object datasource)35 public boolean triggerToolBarItem(long activationType, Object datasource); 36 setDefaultActivationListener( UIToolBarActivationListener toolBarActivation)37 public void setDefaultActivationListener( 38 UIToolBarActivationListener toolBarActivation); 39 setAlwaysAvailable(boolean b)40 public void setAlwaysAvailable(boolean b); 41 getTooltipID()42 public String getTooltipID(); 43 getDefaultActivationListener()44 public UIToolBarActivationListener getDefaultActivationListener(); 45 addToolBarItemListener(ToolBarItemListener l)46 public void addToolBarItemListener(ToolBarItemListener l); 47 removeToolBarItemListener(ToolBarItemListener l)48 public void removeToolBarItemListener(ToolBarItemListener l); 49 } 50