00001 /* 00002 * Copyright (C) 2004 emuWorks 00003 * http://games.technoplaza.net/ 00004 * 00005 * This program is free software; you can redistribute it and/or 00006 * modify it under the terms of the GNU General Public License 00007 * as published by the Free Software Foundation; either version 2 00008 * of the License, or (at your option) any later version. 00009 * 00010 * This program is distributed in the hope that it will be useful, 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 * GNU General Public License for more details. 00014 * 00015 * You should have received a copy of the GNU General Public License 00016 * along with this program; if not, write to the Free Software 00017 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00018 */ 00019 00020 // $Id: FileDropTarget.hh,v 1.1 2004/12/08 05:11:10 technoplaza Exp $ 00021 00022 #ifndef _FILE_DROP_TARGET_HH 00023 #define _FILE_DROP_TARGET_HH 00024 00025 #include <wx/dnd.h> 00026 00027 #include "MainFrame.hh" 00028 00029 namespace ffse { 00030 class MainFrame; 00031 00032 /** 00033 * Class implementing a wxFileDropTarget for the MainFrame class. 00034 */ 00035 class FileDropTarget : public wxFileDropTarget { 00036 public: 00037 /** 00038 * Constructor for the FileDropTarget. 00039 * 00040 * @param owner The MainFrame associated with this FileDropTarget. 00041 */ 00042 FileDropTarget(MainFrame *owner) { this->owner = owner; } 00043 00044 /** 00045 * Virtual method called when files are dropped on this target. 00046 * 00047 * @param x The x-coordinate of the drop. 00048 * @param y The y-coordinate of the drop. 00049 * @param files The files dropped on this target. 00050 */ 00051 virtual bool OnDropFiles(wxCoord x, wxCoord y, 00052 const wxArrayString &files); 00053 private: 00054 MainFrame *owner; 00055 }; 00056 } 00057 00058 #endif 00059