moved kdeaccessibility kdeaddons kdeadmin kdeartwork kdebindings kdeedu kdegames...
[kdeedu.git] / kwordquiz / src / dlgsort.cpp
blob099ec8f5643f91f249e677ca5d5bd3faab361a96
1 /***************************************************************************
2 dlglsort.cpp - description
3 -------------------
4 copyright : (C) 2003 by Peter Hedlund
5 email : peter@peterandlinda.com
6 ***************************************************************************/
8 /***************************************************************************
9 * *
10 * This program is free software; you can redistribute it and/or modify *
11 * it under the terms of the GNU General Public License as published by *
12 * the Free Software Foundation; either version 2 of the License, or *
13 * (at your option) any later version. *
14 * *
15 ***************************************************************************/
17 #include <klocale.h>
19 #include <qradiobutton.h>
21 #include "dlgsort.h"
24 DlgSort::DlgSort(QWidget *parent, const char *name, bool modal): KDialogBase(Swallow, i18n("Sort"), Ok|Cancel, Ok, parent, name, modal, true)
26 dlgBase = new DlgSortBase( this, "Dlg" );
27 setMainWidget(dlgBase);
29 dlgBase->optLang1->setChecked(true);
30 dlgBase->optAscending->setChecked(true);
31 dlgBase->optLang1->setFocus();
34 DlgSort::~DlgSort()
38 bool DlgSort::base( )
40 return dlgBase->optLang1->isChecked();
43 bool DlgSort::ascending( )
45 return dlgBase->optAscending->isChecked();
48 void DlgSort::setLanguage( int index, const QString & lang )
50 if (index == 1) {
51 dlgBase->optLang1 -> setText("&1 " + lang);
53 else
55 dlgBase->optLang2 -> setText("&2 " + lang);
60 #include "dlgsort.moc"