• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdenetwork API Reference
  • KDE Home
  • Contact Us
 

kget

  • sources
  • kde-4.12
  • kdenetwork
  • kget
  • ui
  • mirror
mirrorsettings.h
Go to the documentation of this file.
1 /***************************************************************************
2 * Copyright (C) 2009 Matthias Fuchs <mat69@gmx.net> *
3 * *
4 * This program is free software; you can redistribute it and/or modify *
5 * it under the terms of the GNU General Public License as published by *
6 * the Free Software Foundation; either version 2 of the License, or *
7 * (at your option) any later version. *
8 * *
9 * This program is distributed in the hope that it will be useful, *
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
12 * GNU General Public License for more details. *
13 * *
14 * You should have received a copy of the GNU General Public License *
15 * along with this program; if not, write to the *
16 * Free Software Foundation, Inc., *
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . *
18 ***************************************************************************/
19 
20 #ifndef MIRRORSETTINGS_H
21 #define MIRRORSETTINGS_H
22 
23 #include "mirrormodel.h"
24 #include "../../core/basedialog.h"
25 
26 #include "ui_mirrorsettings.h"
27 #include "ui_mirroradddlg.h"
28 
29 class QSortFilterProxyModel;
30 class TransferHandler;
31 
32 class MirrorAddDlg : public KDialog
33 {
34  Q_OBJECT
35 
36  public:
37  explicit MirrorAddDlg(MirrorModel *model, QWidget *parent = 0, Qt::WFlags flags = 0);
38  explicit MirrorAddDlg(MirrorModel *model, QSortFilterProxyModel *countryModel, QWidget *parent = 0, Qt::WFlags flags = 0);
39 
40  virtual QSize sizeHint() const;
41 
48  void showItem(MirrorItem::DataType type, bool show);
49 
50  private slots:
51  void addMirror();
52  void updateButton(const QString &text = QString());
53 
54  private:
55  void init();
56 
57  private:
58  Ui::MirrorAddDlg ui;
59  MirrorModel *m_model;
60  QSortFilterProxyModel *m_countryModel;
61 };
62 
63 class MirrorSettings : public KGetSaveSizeDialog
64 {
65  Q_OBJECT
66 
67  public:
68  MirrorSettings(QWidget *parent, TransferHandler *handler, const KUrl &file);
69 
70  virtual QSize sizeHint() const;
71 
72  private slots:
73  void updateButton();
74  void addClicked();
75  void removeMirror();
76  void save();
77 
78  private:
79  TransferHandler *m_transfer;
80  KUrl m_file;
81  MirrorModel *m_model;
82  MirrorProxyModel *m_proxy;
83  Ui::MirrorSettings ui;
84 };
85 
86 #endif
MirrorSettings::sizeHint
virtual QSize sizeHint() const
Definition: mirrorsettings.cpp:153
TransferHandler
Class TransferHandler:
Definition: transferhandler.h:48
MirrorSettings
Definition: mirrorsettings.h:63
QWidget
KDialog
MirrorModel
Definition: mirrormodel.h:88
MirrorAddDlg::MirrorAddDlg
MirrorAddDlg(MirrorModel *model, QWidget *parent=0, Qt::WFlags flags=0)
Definition: mirrorsettings.cpp:26
MirrorProxyModel
Definition: mirrormodel.h:49
MirrorItem::DataType
DataType
Definition: mirrormodel.h:65
MirrorSettings::MirrorSettings
MirrorSettings(QWidget *parent, TransferHandler *handler, const KUrl &file)
Definition: mirrorsettings.cpp:121
KGetSaveSizeDialog
Subclass to make sure that the size of the dialog is automatically stored and restored.
Definition: basedialog.h:32
MirrorAddDlg::showItem
void showItem(MirrorItem::DataType type, bool show)
Shows or hides elements, by default all (expect MirrorItem::Used) are shown.
Definition: mirrorsettings.cpp:72
MirrorAddDlg
Definition: mirrorsettings.h:32
QSortFilterProxyModel
MirrorAddDlg::sizeHint
virtual QSize sizeHint() const
Definition: mirrorsettings.cpp:42
mirrormodel.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:53:17 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kget

Skip menu "kget"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdenetwork API Reference

Skip menu "kdenetwork API Reference"
  • kget
  • kopete
  •   kopete
  •   libkopete
  • krdc
  • krfb

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal