/***************************************************************************
                            KDataToolAction.java -  description
                             -------------------
    begin                : Sun Jan 27 16:22:17 2002
    copyright            : (C) 2000-2001 Lost Highway Ltd.
    email                : Richard_Dale@tipitina.demon.co.uk
    generated by         : duke@tipitina on Sun Jan 27 16:22:17 2002, using kalyptus 0.9.
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
***************************************************************************/

package org.kde.koala;

import org.kde.qt.*;
import java.util.*;
import java.lang.Error;

/**

 This class helps applications implement support for KDataTool.
 The steps to follow are simple:
 1) query for the available tools using KDataToolInfo.query
 2) pass the result to KDataToolAction.dataToolActionList (with a slot)
 3) plug the resulting actions, either using KXMLGUIClient.plugActionList, or by hand.

 The slot defined for step 2 is called when the action is activated, and
 that's where the tool should be created and run.
 
 See {@link KDataToolActionSignals} for signals emitted by KDataToolAction.

 See {@link KDataToolActionEventHandling} for event handlers to override in subclasses of KDataToolAction.

 @short 
 This class helps applications implement support for KDataTool.
*/
public class KDataToolAction extends KAction  {
	protected KDataToolAction(Class dummy){super((Class) null);}

	private native void newKDataToolAction( String text, KDataToolInfo info, String command, QObject parent, String name);
	public KDataToolAction( String text, KDataToolInfo info, String command, QObject parent, String name) {
		super((Class) null);
		newKDataToolAction( text, info, command, parent, name);
	}
	private native void newKDataToolAction( String text, KDataToolInfo info, String command);
	public KDataToolAction( String text, KDataToolInfo info, String command) {
		super((Class) null);
		newKDataToolAction( text, info, command);
	}

/** 
 Creates a list of actions from a list of information about data-tools.
 The slot must have a signature corresponding to the {@link toolActivated} signal.

 Note that it's the caller's responsibility to delete the actions when they're not needed anymore.
     
*/
//	public static native QPtrList<KAction> dataToolActionList( KDataToolInfoValueList tools, QObject receiver, String slot);
	protected native void slotActivated();
}
