47 #ifndef OPTIONSWIDGET_HH 48 #define OPTIONSWIDGET_HH 50 #include <OpenFlipper/Core/PluginInfo.hh> 51 #include <ACG/Scenegraph/DrawModes.hh> 53 #include "ui_optionsWidget.h" 55 #include <QStringList> 56 #include <QProgressDialog> 61 typedef std::multimap< std::pair< QObject*, int >, std::pair< int, Qt::KeyboardModifiers > > InverseKeyMap;
70 OptionsWidget(std::vector<PluginInfo>& _plugins, std::vector<KeyBinding>& _core, InverseKeyMap& _invKeys, QWidget* parent =0 );
76 void addKeyMapping(
int _key, Qt::KeyboardModifiers _modifiers, QObject* _plugin,
int _keyBindingID);
95 void getDefaultColor();
104 void slotShowPluginOptions(
const QString& _pluginName );
134 void showEvent ( QShowEvent * event );
139 void initPluginOptions();
141 QVBoxLayout* pluginOptionsLayout;
144 std::vector<PluginInfo>& plugins_;
145 std::vector<KeyBinding>& coreKeys_;
147 InverseKeyMap& keys_;
156 bool httpRequestAborted;
160 QNetworkAccessManager *networkMan_;
162 QNetworkReply* downloadRep_;
168 QProgressDialog *progressDialog_;
179 std::vector< ACG::SceneGraph::DrawModes::DrawMode > defaultDrawModes_;
180 std::vector< bool > defaultProjectionMode_;
181 std::vector< int > defaultViewingDirections_;
182 std::vector< bool > defaultRotationLocks_;
184 bool updatingViewerSettings_;
187 QColor backgroundColor_;
197 bool isNewer(QString _current, QString _latest);
205 void httpRequestFinished(QNetworkReply *_qnr);
208 void updateDataReadProgress(qint64 _bytesReceived, qint64 _bytesTotal);
211 void showError(QNetworkReply::NetworkError _error);
214 void cancelDownload();
217 void updateComponent();
220 void slotTranslationIndexChanged(
int);
223 void authentication ( QNetworkReply* _reply, QAuthenticator* _authenticator );
246 #endif //OPTIONSWIDGET_HH void getBackgroundColor()
open a dialog to determine the color
void slotClearSettings()
Clear all OpenFlipper settings.
void slotPreviewStereoSettings(int _tmpParam=0)
void slotCheckUpdates()
Checks for updates.
void updateShortcut()
check if the shortcut exists and add it if not
void authentication(QNetworkReply *_reply, QAuthenticator *_authenticator)
authentication
void initKeyTree()
init the TreeWidget containing the keyBindings
void compareVersions()
Compares the versions from the downloaded Versions file with the current versions.
void switchStackedWidget()
Switch between the stacked widgets of the stereo settings.
void updateVersionsTable()
Redraws the version table.
void slotCancel()
Only hide widget.
void updateViewerSettings(int _row)
update the dialog if the selected viewer changes
void keyTreeDoubleClicked(QTreeWidgetItem *_item, int col)
doubleclick in the keyTree
void viewerSettingsChanged(QListWidgetItem *_item)
remember user changes to viewer properties
QStringList updatedPlugins_
void applyShortcuts()
check which of the shortcuts changed and inform the core about the change
void slotGetUpdates()
Download updates.
void slotClearINI()
Clear OpenFlipper INI.
void showError(QNetworkReply::NetworkError _error)
error occured while downloading
int getPluginInfo(QString pluginName)
get the pluginInfo object corresponding to the given pluginName
void keyTreeItemChanged(QTreeWidgetItem *current, QTreeWidgetItem *previous)
keyBinding TreeWidget-Item changed
bool isNewer(QString _current, QString _latest)
Compares two version strings and returns if a newer Version is available.
void slotReloadShaders()
Clear the Shader Cache.
void startDownload(QString _url)
Starts the download of the given file.
void restoreKeyPresets()
restore keyBinding Presets
void slotApply()
Update Options and tell others about changed Options.
QString currentUpdateName_
void slotOk()
call slotApply and hide widget