⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 uifltk-about.cpp

📁 一个任天堂掌上游戏机NDS的源代码
💻 CPP
字号:
/*************************************************************************** DSemu - The Next Generation                                             ** Fltk user interface: Log file viewer [uifltk-log.cpp]                   ** Copyright Imran Nazar, 2005; released under the BSD public licence.     ** Fltk used under the terms of the LGPL.                                  ***************************************************************************/#include <FL/Fl.h>#include "uifltk.h"const char *UIFltk::UI::AboutWindow::aboutTxt="\n\n\DSemu - The Next Generation\n\Copyright Imran Nazar, 2004-2005.\n\Released under the BSD Public Licence.\n\FLTK used under the LGPL.\n\PortAudio used under the BSD Public Licence.\n\\n\Code portions from:\n\Commodore Hacking #8\n\    (Signed long mul negation policy)\n\Costis\n\    (LDM disassembly algorithm, original)\n\Donald Knuth\n\    (Sidesum algorithm)\n\gladius\n\    (tile and rotated BG, and sprite renderers)\n\Kniht\n\    (Configuration reads, stream-based logging)\n\mic\n\    (Consistent debugging help and discussion)\n\Mike Murphy [emu7800.sf.net]\n\    (V flag setting inspired by M6502)\n\Mark Andrews, 'Atari Roots'\n\    (Long mul algorithm extended)\n\Parallel Computing, Kentucky U\n\    (nlpo2 function)\n\Stephen Stair\n\    (DP addressing, _RN overwrite if Rn=Rd fix)\n\\n\Redistribution and use in source and\n\binary forms, with or without\n\modification, are permitted provided\n\that the following conditions are met:\n\\n\Redistributions of source code must\n\retain the above copyright notice,\n\this list of conditions and the\n\following disclaimer.\n\\n\Redistributions in binary form must\n\reproduce the above copyright notice,\n\this list of conditions and the\n\following disclaimer in the documen-\n\tation and/or other materials provided\n\with the distribution.\n\\n\THIS SOFTWARE IS PROVIDED BY THE\n\COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS\n\IS' AND ANY EXPRESS OR IMPLIED WARRAN-\n\TIES, INCLUDING, BUT NOT LIMITED TO,\n\THE IMPLIED WARRANTIES OF MERCHANT-\n\ABILITY AND FITNESS FOR A PARTICULAR\n\PURPOSE ARE DISCLAIMED. IN NO EVENT\n\SHALL THE COPYRIGHT OWNER OR CONTRIB-\n\UTORS BE LIABLE FOR ANY DIRECT,\n\INDIRECT, INCIDENTAL, SPECIAL,\n\EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n\(INCLUDING, BUT NOT LIMITED TO,\n\PROCUREMENT OF SUBSTITUTE GOODS OR\n\SERVICES; LOSS OF USE, DATA, OR\n\PROFITS; OR BUSINESS INTERRUPTION)\n\HOWEVER CAUSED AND ON ANY THEORY OF\n\LIABILITY, WHETHER IN CONTRACT, STRICT\n\LIABILITY, OR TORT (INCLUDING NEGLIG-\n\ENCE OR OTHERWISE) ARISING IN ANY WAY\n\OUT OF THE USE OF THIS SOFTWARE, EVEN\n\IF ADVISED OF THE POSSIBILITY OF\n\SUCH DAMAGE.\n";Fl_Text_Buffer *UIFltk::UI::AboutWindow::buf;Fl_Text_Display *UIFltk::UI::AboutWindow::text;Fl_Button *UIFltk::UI::AboutWindow::ok;Fl_Window *UIFltk::UI::AboutWindow::mainWnd;// Initialise windowUIFltk::UI::AboutWindow::AboutWindow(int w, int h, void *t)	: Fl_Double_Window(w,h,"About DSemu-ng"){    mainWnd = (Fl_Window*)t;	    // Add controls (there's only one visible)    begin();        buf = new Fl_Text_Buffer();        text = new Fl_Text_Display(5,5, 340,340);	text->box(FL_NO_BOX);	text->buffer(buf);        text->hide_cursor();	text->textsize(10);	text->textcolor(FL_BLACK);	text->textfont(FL_COURIER);	text->color(FL_WHITE);	ok = new Fl_Button(265,355, 80,30, "OK");	ok->callback(cbOK, this);	ok->labelsize(11);    end();    resizable(text);    show();    // Initialise the buffer    cb(this);}// Shut down window: remove log refresh timeoutUIFltk::UI::AboutWindow::~AboutWindow(){    hide();}// Refresh windowvoid UIFltk::UI::AboutWindow::cb(void *in){    buf->append(DSEMU_VERSION_STR);    buf->append(aboutTxt);}// Handle window events. In this case, there's only one we need to know// about: if the window gets hidden, tell the main UI.int UIFltk::UI::AboutWindow::handle(int e){    int ret = Fl_Window::handle(e);    switch(e)    {        case FL_HIDE:            Fl::handle(0xBEEF0002, mainWnd);	    break;    }    return ret;}void UIFltk::UI::AboutWindow::cbOK(Fl_Widget *w, void *in) { ((UIFltk::UI::AboutWindow*)in)->cbOKI(); }inline void UIFltk::UI::AboutWindow::cbOKI(){    hide();}/*** EOF: uifltk-log.cpp *************************************************/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -