43 #ifndef QT_NO_WIN_ACTIVEQT 56 RegOpenKeyEx(HKEY_CLASSES_ROOT, L
"CLSID", 0, KEY_READ, &classes_key);
63 DWORD szBuffer =
sizeof(buffer) /
sizeof(
wchar_t);
66 result = RegEnumKeyEx(classes_key, index, buffer, &szBuffer, 0, 0, 0, &ft);
67 szBuffer =
sizeof(buffer) /
sizeof(
wchar_t);
68 if (result == ERROR_SUCCESS) {
71 result = RegOpenKeyEx(classes_key, reinterpret_cast<const wchar_t *>(
QString(clsid +
"\\Control").utf16()), 0, KEY_READ, &sub_key);
72 if (result == ERROR_SUCCESS) {
80 result = ERROR_SUCCESS;
82 szBuffer =
sizeof(buffer) /
sizeof(
wchar_t);
84 }
while (result == ERROR_SUCCESS);
85 RegCloseKey(classes_key);
91 LONG ret = ERROR_FILE_NOT_FOUND;
93 RegOpenKeyEx(hKey, lpSubKey, 0, KEY_READ, &hSubKey);
95 ret = RegQueryValueEx(hSubKey, 0, 0, 0, lpData, lpcbData);
136 ActiveXList->setFocus();
157 #endif // QT_NO_WIN_ACTIVEQT The QVariant class acts like a union for the most common Qt data types.
static QString fromWCharArray(const wchar_t *, int size=-1)
Returns a copy of the string, where the encoding of string depends on the size of wchar...
#define QT_END_NAMESPACE
This macro expands to.
The QDialog class is the base class of dialog windows.
virtual void accept()
Hides the modal dialog and sets the result code to Accepted.
virtual void reject()
Hides the modal dialog and sets the result code to Rejected.
QString toString() const
Returns the variant as a QString if the variant has type() String , Bool , ByteArray ...
int count(const T &t) const
Returns the number of occurrences of value in the list.
The QAbstractListModel class provides an abstract model that can be subclassed to create one-dimensio...
QAxSelect(QWidget *parent=0, Qt::WindowFlags f=0)
The QString class provides a Unicode character string.
ControlList(QObject *parent=0)
The QObject class is the base class of all Qt objects.
void on_ActiveXList_clicked(const QModelIndex &index)
QChar * data()
Returns a pointer to the data stored in the QString.
QModelIndex index(int row, int column=0, const QModelIndex &parent=QModelIndex()) const
Returns the index of the data in row and column with parent.
LONG RegistryQueryValue(HKEY hKey, LPCWSTR lpSubKey, LPBYTE lpData, LPDWORD lpcbData)
QMap< QString, QString > clsids
#define QT_BEGIN_NAMESPACE
This macro expands to.
void sort()
Sorts the list of strings in ascending order (case sensitively).
QVariant data(const QModelIndex &index, int role) const
Returns the data stored under the given role for the item referred to by the index.
static bool connect(const QObject *sender, const char *signal, const QObject *receiver, const char *member, Qt::ConnectionType=Qt::AutoConnection)
Creates a connection of the given type from the signal in the sender object to the method in the rece...
int row() const
Returns the row this model index refers to.
const T value(const Key &key) const
Returns the value associated with the key key.
const T & at(int i) const
Returns the item at index position i in the list.
The QStringList class provides a list of strings.
bool isValid() const
Returns true if this model index is valid; otherwise returns false.
int rowCount(const QModelIndex &=QModelIndex()) const
Returns the number of rows under the given parent.
void on_ActiveXList_doubleClicked(const QModelIndex &index)
iterator insert(const Key &key, const T &value)
Inserts a new item with the key key and a value of value.
QObject * parent() const
Returns a pointer to the parent object.
The QModelIndex class is used to locate data in a data model.
static void setOverrideCursor(const QCursor &)
Use changeOverrideCursor(cursor) (if replace is true) or setOverrideCursor(cursor) (if replace is fal...
static void restoreOverrideCursor()
Undoes the last setOverrideCursor().