| Home · All Namespaces · All Classes |
#include <switcherviewbase.h>


Signals | |
| void | animationStateChanged (bool animating) |
Public Member Functions | |
| SwitcherViewBase (Switcher *controller) | |
| virtual | ~SwitcherViewBase () |
| bool | event (QEvent *e) |
Protected Slots | |
| virtual void | updateData (const QList< const char * > &modifications) |
| REIMPLEMENTATION | |
| virtual void | endTransition () |
| | |
| virtual void | endBounce () |
| virtual void | applyPinchGestureTargetMode () |
| void | runOverviewBounceAnimation () |
| virtual void | updateAnimationStatus () |
Protected Member Functions | |
| virtual void | setupModel () |
| | |
| virtual void | pinchGestureEvent (QGestureEvent *event, QPinchGesture *gesture) |
| virtual bool | sceneEventFilter (QGraphicsItem *watched, QEvent *event) |
| virtual void | applySwitcherMode () |
| | |
| void | removeButtonsFromLayout () |
| int | buttonIndex (const SwitcherButton *button) const |
| void | calculateNearestButtonAt (const QPointF ¢erPoint) |
| Calculates which switcher button is nearest to point centerPoint. | |
| virtual void | startBounceAnimation () |
| void | setInwardBounceAnimation (bool i) |
| virtual void | pinchBegin (const QPointF ¢erPoint) |
| virtual void | pinchUpdate (float scaleFactor) |
| virtual void | pinchEnd () |
Protected Attributes | |
| Switcher * | controller |
| QGraphicsLinearLayout * | mainLayout |
| MWidget * | pannedWidget |
| MLayout * | pannedLayout |
| int | pinchedButtonPosition |
| TransformLayoutAnimation * | layoutAnimation |
| bool | overpinch |
| QPropertyAnimation * | bounceAnimation |
| SwitcherModel::Mode | pinchGestureTargetMode |
| MPannableViewport * | viewport |
| bool | animating |
The switcher view draws a background for the switcher.
| SwitcherViewBase::SwitcherViewBase | ( | Switcher * | controller | ) |
Constructs a SwitcherViewBase.
| container | the Switcher controller to be used |
| SwitcherViewBase::~SwitcherViewBase | ( | ) | [virtual] |
Destroys the SwitcherViewBase.
| void SwitcherViewBase::animationStateChanged | ( | bool | animating | ) | [signal] |
Sent when switcher starts or stops animating
| void SwitcherViewBase::applyPinchGestureTargetMode | ( | ) | [protected, virtual, slot] |
Sets the switcher mode according to current pinch gesture target
Reimplemented in SwitcherView.
| void SwitcherViewBase::applySwitcherMode | ( | ) | [protected, virtual] |
Selects the layout policy and sets up switcher mode dependent signals
Reimplemented in SwitcherView.
| int SwitcherViewBase::buttonIndex | ( | const SwitcherButton * | button | ) | const [protected] |
Returns the index of a SwitcherButton in the model or -1, if not found
| void SwitcherViewBase::calculateNearestButtonAt | ( | const QPointF & | centerPoint | ) | [protected] |
Calculates which switcher button is nearest to point centerPoint.
| void SwitcherViewBase::endBounce | ( | ) | [protected, virtual, slot] |
Ends the bounce effect
| void SwitcherViewBase::endTransition | ( | ) | [protected, virtual, slot] |
Ends the transition between switcher modes
| bool SwitcherViewBase::event | ( | QEvent * | e | ) |
REIMPLEMENTATION Re-implented event handler. Needed to enable gestures.
| e | event to be handled |
| void SwitcherViewBase::pinchBegin | ( | const QPointF & | centerPoint | ) | [protected, virtual] |
Called when the pinch gesture starts
| centerPoint | the center point of the pinch gesture |
| void SwitcherViewBase::pinchEnd | ( | ) | [protected, virtual] |
Called when the pinch gesture ends
| void SwitcherViewBase::pinchGestureEvent | ( | QGestureEvent * | event, | |
| QPinchGesture * | gesture | |||
| ) | [protected, virtual] |
Re-implemented to handle the mode switch
| event | Gesture event class for general event handling. | |
| gesture | Pinch gesture class. Contains all pinch specific information |
Finish any currently running animation before starting a new one
| void SwitcherViewBase::pinchUpdate | ( | float | scaleFactor | ) | [protected, virtual] |
Called to update the scale factor during the pinch gesture
| scaleFactor | the updated scale factor |
| void SwitcherViewBase::removeButtonsFromLayout | ( | ) | [protected] |
Remove all buttons from layout and set parents to NULL Parents are set to NULL to avoid double deletion as buttons are QSharedPointer's in model
| void SwitcherViewBase::runOverviewBounceAnimation | ( | ) | [protected, slot] |
Runs the bounce animation if currently in overview mode
| bool SwitcherViewBase::sceneEventFilter | ( | QGraphicsItem * | watched, | |
| QEvent * | event | |||
| ) | [protected, virtual] |
Filters QGraphicsSceneMouseMove events from SwitcherButtons.
| void SwitcherViewBase::setInwardBounceAnimation | ( | bool | i | ) | [protected] |
Sets the direction of the bounce animation
| void SwitcherViewBase::setupModel | ( | ) | [protected, virtual] |
REIMPLEMENTATION Re-implemented here to get an update when the model is set
| void SwitcherViewBase::startBounceAnimation | ( | ) | [protected, virtual] |
Starts the bounce animation
| void SwitcherViewBase::updateAnimationStatus | ( | ) | [protected, virtual, slot] |
Updates the animation status and sends animationStateChanged signal if status changed
| void SwitcherViewBase::updateData | ( | const QList< const char * > & | modifications | ) | [protected, virtual, slot] |
REIMPLEMENTATION
Reimplemented in SwitcherView.
bool SwitcherViewBase::animating [protected] |
True if switcher is currently animating
QPropertyAnimation* SwitcherViewBase::bounceAnimation [protected] |
Animation for the bounce when going to overview mode and when overpinching
Switcher* SwitcherViewBase::controller [protected] |
The switcher controller
Layout animation for animating switcher buttons
QGraphicsLinearLayout* SwitcherViewBase::mainLayout [protected] |
Layouts
bool SwitcherViewBase::overpinch [protected] |
True if the pinch direction is to the mode we're already in
MLayout* SwitcherViewBase::pannedLayout [protected] |
Layout for the panned widget
MWidget* SwitcherViewBase::pannedWidget [protected] |
The widget that will contain all of the switcher buttons
int SwitcherViewBase::pinchedButtonPosition [protected] |
The button being currently pinched
The target mode for pinch gesture
MPannableViewport* SwitcherViewBase::viewport [protected] |
The viewport that shows the switcher buttons
| Copyright © 2010 Nokia Corporation | Generated on Sun Feb 6 23:02:53 2011 Doxygen 1.6.1 |
MeeGo Touch |