File indexing completed on 2024-12-22 04:17:43
0001 /*************************************************************************** 0002 * * 0003 * copyright : (C) 2010 The University of Toronto * 0004 * netterfield@astro.utoronto.ca * 0005 * * 0006 * This program is free software; you can redistribute it and/or modify * 0007 * it under the terms of the GNU General Public License as published by * 0008 * the Free Software Foundation; either version 2 of the License, or * 0009 * (at your option) any later version. * 0010 * * 0011 ***************************************************************************/ 0012 0013 #include "pluginmenuitemaction.h" 0014 0015 namespace Kst { 0016 0017 PluginMenuItemAction::PluginMenuItemAction(const QString &text, QWidget *parent) 0018 : QAction(parent), 0019 m_text(text) { 0020 connect(this, SIGNAL(triggered()), this, SLOT(triggerWithName())); 0021 this->setText(text); 0022 } 0023 0024 void PluginMenuItemAction::triggerWithName() { 0025 emit triggered(m_text); 0026 } 0027 0028 } 0029 0030 // vim: ts=2 sw=2 et 0031