+/*
+ Situare - A location system for Facebook
+ Copyright (C) 2010 Ixonos Plc. Authors:
+
+ Jukka Saastamoinen - jukka.saastamoinen@ixonos.com
+
+ Situare is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License
+ version 2 as published by the Free Software Foundation.
+
+ Situare is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with Situare; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
+ USA.
+*/
+
+#include <QPainter>
#include "buttonitem.h"
+
ButtonItem::ButtonItem(QWidget *parent)
: QPushButton(parent)
{
}
-ButtonItem::~ButtonItem()
-{
-
-}
-
void ButtonItem::paintEvent(QPaintEvent *aPaintEvent)
{
//Look and feel settings
QSize ButtonItem::sizeHint() const
{
- return iconSize();
+ return this->iconSize();
}
#ifndef BUTTONITEM_H
#define BUTTONITEM_H
-#include <QtGui>
+#include <QPushButton>
class ButtonItem : public QPushButton
{
* @param parent Parent
*/
ButtonItem(QWidget *parent = 0);
- ~ButtonItem();
/*******************************************************************************
* BASE CLASS INHERITED AND REIMPLEMENTED MEMBER FUNCTIONS
* @brief This function returns the preferred size of the button
* for the layout using it.
*
- * @return Size of the button
+ * @return QSize Size of the button
*/
QSize sizeHint() const;
-/*******************************************************************************
-* DATA MEMBERS
-*******************************************************************************/
-private:
- QSize size;
};
#endif // BUTTONITEM_H
QString m_time; ///< Time when the new message was sent
QPixmap m_avatar; ///< User's avatar
QWidget *widget; ///< Parent of all widgets.
- SituareUser *situUser;
+ SituareUser *situUser; ///< Situare user's framed picture
};
#endif // INFOTAB_H
#include "listviewscreen.h"
#include "situareuser.h"
#include <QDebug>
+#include <QGraphicsRotation>
ListViewScreen::ListViewScreen(QWidget *parent)
: QWidget(parent)
scene->addItem(m_arrowRight);
m_leftSideBar->setPos(0,0);
+ QGraphicsRotation rotation(m_arrowRight);
+ rotation.setAxis(Qt::YAxis);
+ rotation.setOrigin(QVector3D(size().width()/2, size().height()/2, 0));
+
QGraphicsView *view = new QGraphicsView(scene);
view->setAlignment(Qt::AlignLeft|Qt::AlignTop);
view->setSceneRect(0,0,7000,3000);
state2->assignProperty(m_slidingLeftSideBar,"pos",QPointF(376,0));
state2->assignProperty(m_personalInfoBackGround,"pos",QPointF(0,0));
state2->assignProperty(m_arrowRight,"pos", QPointF(385,205));
+ state2->assignProperty(m_arrowRight,"angle", 180);
m_trans1 = state1->addTransition(m_slidingLeftSideBar,SIGNAL(clicked()),state2);
m_anim1 = new QPropertyAnimation(m_widgetProxy,"pos");
m_anim4 = new QPropertyAnimation(m_slidingLeftSideBar,"pos");
m_anim6 = new QPropertyAnimation(m_personalInfoBackGround,"pos");
m_anim8 = new QPropertyAnimation(m_arrowRight,"pos");
+ m_anim9 = new QPropertyAnimation(&rotation,"angle");
m_trans2->addAnimation(m_anim3);
m_trans2->addAnimation(m_anim4);
m_trans2->addAnimation(m_anim6);
m_trans2->addAnimation(m_anim8);
-
+ m_trans2->addAnimation(m_anim9);
machine->start();
m_vbox = new QVBoxLayout(this);
delete m_anim5;
if (m_anim6)
delete m_anim6;
+ if (m_anim7)
+ delete m_anim7;
+ if (m_anim8)
+ delete m_anim8;
if (m_vbox)
delete m_vbox;
}
QPropertyAnimation *m_anim6; ///< Animation for arrowbutton from visible to hidden
QPropertyAnimation *m_anim7;
QPropertyAnimation *m_anim8;
+ QPropertyAnimation *m_anim9;
UpdateLocationDialog *m_locationDialog; ///< Message dialog
};
#endif // LISTVIEWTAB_H
-
-
-#endif // LISTVIEWTAB_H
\ No newline at end of file
+/*
+ Situare - A location system for Facebook
+ Copyright (C) 2010 Ixonos Plc. Authors:
+
+ Jukka Saastamoinen - jukka.saastamoinen@ixonos.com
+
+ Situare is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License
+ version 2 as published by the Free Software Foundation.
+
+ Situare is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with Situare; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
+ USA.
+*/
+
#include "situareuser.h"
#include <QPainter>
#include <QDebug>
QRegion maskRegion = painter.clipRegion();
setMask(maskRegion);
- //qDebug() << "Current clip region: " << painter.clipRegion();
- qDebug() << "Current mask region: " << maskRegion.boundingRect();
+
painter.drawPixmap(QPointF(0,0),(*(this->pixmap())));
painter.drawPixmap(QPointF(-6,-6),(QPixmap(":/resources/profile_pic_border.png")));
painter.restore();
+/*
+ Situare - A location system for Facebook
+ Copyright (C) 2010 Ixonos Plc. Authors:
+
+ Jukka Saastamoinen - jukka.saastamoinen@ixonos.com
+
+ Situare is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License
+ version 2 as published by the Free Software Foundation.
+
+ Situare is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with Situare; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
+ USA.
+*/
+
#ifndef SITUAREUSER_H
#define SITUAREUSER_H
* @param aPaintEvent Pointer to paint event
*/
void paintEvent(QPaintEvent *aPaintEvent);
+ /**
+ * @brief This function suggests layouter correct size.
+ *
+ * @return QSize Size of the label
+ */
+ QSize sizeHint() const;
public:
+ /**
+ * @brief Constructor
+ *
+ * @param parent Parent
+ */
SituareUser(QWidget *parent=0);
- QSize sizeHint() const;
-private:
- QPixmap m_p;
};
#endif // SITUAREUSER_H