xref: /haiku/src/add-ons/translators/sgi/SGIMain.cpp (revision 97c990977207d3fb1acc0b6b8535bef05fe73665)
19949213aSStephan Aßmus /*****************************************************************************/
29949213aSStephan Aßmus // SGITranslator
39949213aSStephan Aßmus // Adopted by Stephan Aßmus, <stippi@yellowbites.com>
49949213aSStephan Aßmus // from TIFFMain written by
59949213aSStephan Aßmus // Michael Wilber, OBOS Translation Kit Team
69949213aSStephan Aßmus //
79949213aSStephan Aßmus // Version:
89949213aSStephan Aßmus //
99949213aSStephan Aßmus // This translator opens and writes SGI images.
109949213aSStephan Aßmus //
119949213aSStephan Aßmus //
129949213aSStephan Aßmus // This application and all source files used in its construction, except
139949213aSStephan Aßmus // where noted, are licensed under the MIT License, and have been written
149949213aSStephan Aßmus // and are:
159949213aSStephan Aßmus //
169949213aSStephan Aßmus // Copyright (c) 2003 OpenBeOS Project
179949213aSStephan Aßmus //
189949213aSStephan Aßmus // Permission is hereby granted, free of charge, to any person obtaining a
199949213aSStephan Aßmus // copy of this software and associated documentation files (the "Software"),
209949213aSStephan Aßmus // to deal in the Software without restriction, including without limitation
219949213aSStephan Aßmus // the rights to use, copy, modify, merge, publish, distribute, sublicense,
229949213aSStephan Aßmus // and/or sell copies of the Software, and to permit persons to whom the
239949213aSStephan Aßmus // Software is furnished to do so, subject to the following conditions:
249949213aSStephan Aßmus //
259949213aSStephan Aßmus // The above copyright notice and this permission notice shall be included
269949213aSStephan Aßmus // in all copies or substantial portions of the Software.
279949213aSStephan Aßmus //
289949213aSStephan Aßmus // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
299949213aSStephan Aßmus // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
309949213aSStephan Aßmus // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
319949213aSStephan Aßmus // THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
329949213aSStephan Aßmus // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
339949213aSStephan Aßmus // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
349949213aSStephan Aßmus // DEALINGS IN THE SOFTWARE.
359949213aSStephan Aßmus /*****************************************************************************/
369949213aSStephan Aßmus 
379949213aSStephan Aßmus #include <Application.h>
389949213aSStephan Aßmus #include "SGITranslator.h"
399949213aSStephan Aßmus #include "TranslatorWindow.h"
409949213aSStephan Aßmus 
419949213aSStephan Aßmus // ---------------------------------------------------------------
429949213aSStephan Aßmus // main
439949213aSStephan Aßmus //
449949213aSStephan Aßmus // Creates a BWindow for displaying info about the SGITranslator
459949213aSStephan Aßmus //
469949213aSStephan Aßmus // Preconditions:
479949213aSStephan Aßmus //
489949213aSStephan Aßmus // Parameters:
499949213aSStephan Aßmus //
509949213aSStephan Aßmus // Postconditions:
519949213aSStephan Aßmus //
529949213aSStephan Aßmus // Returns:
539949213aSStephan Aßmus // ---------------------------------------------------------------
549949213aSStephan Aßmus int
559949213aSStephan Aßmus main()
569949213aSStephan Aßmus {
57*97c99097SRyan Leavengood 	BApplication app("application/x-vnd.Haiku-SGITranslator");
589949213aSStephan Aßmus 	status_t result;
599949213aSStephan Aßmus 	result = LaunchTranslatorWindow(new SGITranslator,
609949213aSStephan Aßmus 		"SGI Settings", BRect(0, 0, 225, 175));
619949213aSStephan Aßmus 	if (result == B_OK) {
629949213aSStephan Aßmus 		app.Run();
639949213aSStephan Aßmus 		return 0;
649949213aSStephan Aßmus 	} else
659949213aSStephan Aßmus 		return 1;
669949213aSStephan Aßmus }
67