remove comment, styling cleanup

This commit is contained in:
Stephen Birarda 2015-06-26 11:41:34 -07:00
parent c6df573933
commit 522b715628
4 changed files with 12 additions and 7 deletions

View file

@ -17,8 +17,9 @@
#include <avatar/AvatarManager.h> #include <avatar/AvatarManager.h>
#include <gpu/GLBackend.h> #include <gpu/GLBackend.h>
#include <CursorManager.h>
#include <Tooltip.h> #include "CursorManager.h"
#include "HyperLinkTooltip.h"
#include "Application.h" #include "Application.h"

View file

@ -59,7 +59,7 @@ private:
void x::load(std::function<void(QQmlContext*, QObject*)> f) { \ void x::load(std::function<void(QQmlContext*, QObject*)> f) { \
auto offscreenUi = DependencyManager::get<OffscreenUi>(); \ auto offscreenUi = DependencyManager::get<OffscreenUi>(); \
offscreenUi->load(QML, f); \ offscreenUi->load(QML, f); \
} }
#define HIFI_QML_DEF_LAMBDA(x, f) \ #define HIFI_QML_DEF_LAMBDA(x, f) \
const QUrl x::QML = QUrl(#x ".qml"); \ const QUrl x::QML = QUrl(#x ".qml"); \
@ -79,7 +79,7 @@ private:
void x::load() { \ void x::load() { \
auto offscreenUi = DependencyManager::get<OffscreenUi>(); \ auto offscreenUi = DependencyManager::get<OffscreenUi>(); \
offscreenUi->load(QML, f); \ offscreenUi->load(QML, f); \
} }
class OffscreenUi : public OffscreenQmlSurface, public Dependency { class OffscreenUi : public OffscreenQmlSurface, public Dependency {
Q_OBJECT Q_OBJECT
@ -97,7 +97,7 @@ public:
static void messageBox(const QString& title, const QString& text, static void messageBox(const QString& title, const QString& text,
ButtonCallback f, ButtonCallback f,
QMessageBox::Icon icon, QMessageBox::Icon icon,
QMessageBox::StandardButtons buttons); QMessageBox::StandardButtons buttons);
static void information(const QString& title, const QString& text, static void information(const QString& title, const QString& text,

View file

@ -1,5 +1,6 @@
// //
// Tooltip.cpp // Tooltip.cpp
// libraries/ui/src
// //
// Created by Bradley Austin Davis on 2015/04/14 // Created by Bradley Austin Davis on 2015/04/14
// Copyright 2015 High Fidelity, Inc. // Copyright 2015 High Fidelity, Inc.
@ -8,14 +9,17 @@
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
// //
#include "Tooltip.h" #include "Tooltip.h"
#include <QUuid>
#include <QtCore/QUuid>
HIFI_QML_DEF(Tooltip) HIFI_QML_DEF(Tooltip)
Tooltip::Tooltip(QQuickItem* parent) : QQuickItem(parent) { Tooltip::Tooltip(QQuickItem* parent) : QQuickItem(parent) {
} }
Tooltip::~Tooltip() { Tooltip::~Tooltip() {
} }
const QString& Tooltip::getTitle() const { const QString& Tooltip::getTitle() const {
@ -47,7 +51,6 @@ void Tooltip::setVisible(bool visible) {
QString Tooltip::showTip(const QString& title, const QString& description) { QString Tooltip::showTip(const QString& title, const QString& description) {
const QString newTipId = QUuid().createUuid().toString(); const QString newTipId = QUuid().createUuid().toString();
qDebug() << "THE NEW TIP ID IS" << newTipId;
Tooltip::show([&](QQmlContext*, QObject* object) { Tooltip::show([&](QQmlContext*, QObject* object) {
object->setObjectName(newTipId); object->setObjectName(newTipId);
object->setProperty("title", title); object->setProperty("title", title);

View file

@ -1,5 +1,6 @@
// //
// Tooltip.h // Tooltip.h
// libraries/ui/src
// //
// Created by Bradley Austin Davis on 2015/04/14 // Created by Bradley Austin Davis on 2015/04/14
// Copyright 2015 High Fidelity, Inc. // Copyright 2015 High Fidelity, Inc.