/* This file is part of icoformat, a Windows Icon (ICO) File Format plugin for Adobe Photoshop Copyright (C) 2002-3 Toby Thain, toby@telegraphics.com.au 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. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #include #include #include #include "world.h" // must come before Photoshop include #include "ui.h" void DoAbout(AboutRecordPtr prec){ ModalFilterUPP FilterProc_UPP = NewModalFilterUPP(aboutfilter); Alert(ID_ABOUTDLG,FilterProc_UPP); DisposeModalFilterUPP(FilterProc_UPP); } Boolean warntype(StringPtr name,int t){ ModalFilterUPP FilterProc_UPP = NewModalFilterUPP(standardfilter); Str255 s; int res; NumToString(t,s); ParamText(name,s,NULL,NULL); res = CautionAlert(ID_WARNTYPEDLG,FilterProc_UPP) == ok; DisposeModalFilterUPP(FilterProc_UPP); return res; } Boolean pickicondialog(FormatRecordPtr pb,long *data){ ModalFilterUPP FilterProc_UPP = NewModalFilterUPP(standardfilter); short item; DIALOGREF dp; dp = GetNewDialog(ID_PICKICONDLG, NULL, (WindowPtr) -1); pickiconinit(dp,data); SetDialogDefaultItem(dp,ok); InitCursor(); do{ ModalDialog(FilterProc_UPP, &item); }while(pickiconitem(dp,data,item)); DisposeDialog(dp); DisposeModalFilterUPP(FilterProc_UPP); return item == ok; }