001 // GraphLab Project: http://graphlab.sharif.edu 002 // Copyright (C) 2008 Mathematical Science Department of Sharif University of Technology 003 // Distributed under the terms of the GNU General Public License (GPL): http://www.gnu.org/licenses/ 004 package graphlab.plugins.commonplugin.help.actions; 005 006 import graphlab.platform.core.AbstractAction; 007 import graphlab.platform.core.BlackBoard; 008 import graphlab.ui.UIUtils; 009 010 public class Help extends AbstractAction { 011 012 public static final String EVENT_KEY = UIUtils.getUIEventKey("Help"); 013 014 public Help(BlackBoard bb) { 015 super(bb); 016 listen4Event(EVENT_KEY); 017 } 018 019 @Override 020 public void performAction(String eventName, Object value) { 021 new Thread() { 022 public void run() { 023 showHelpWindow(); 024 } 025 }.start(); 026 } 027 028 public static void showHelpWindow() { 029 new graphlab.plugins.commonplugin.help.actions.HelpWindow().setVisible(true); 030 } 031 032 }