mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-24 18:42:12 +08:00
62 lines
2.4 KiB
Diff
62 lines
2.4 KiB
Diff
diff -rup amarok-2.5.0/src/context/toolbar/AppletToolbar.cpp amarok-2.5.0.new/src/context/toolbar/AppletToolbar.cpp
|
|
--- amarok-2.5.0/src/context/toolbar/AppletToolbar.cpp 2011-12-15 08:36:48.000000000 +0100
|
|
+++ amarok-2.5.0.new/src/context/toolbar/AppletToolbar.cpp 2012-01-29 20:20:01.901360205 +0100
|
|
@@ -108,6 +108,17 @@ Context::AppletToolbar::appletRemoved( P
|
|
}
|
|
}
|
|
|
|
+void Context::AppletToolbar::setContainment( Containment * containment )
|
|
+{
|
|
+ m_cont = containment;
|
|
+}
|
|
+
|
|
+Context::Containment *
|
|
+Context::AppletToolbar::containment() const
|
|
+{
|
|
+ return m_cont;
|
|
+}
|
|
+
|
|
QSizeF
|
|
Context::AppletToolbar::sizeHint( Qt::SizeHint which, const QSizeF &constraint ) const
|
|
{
|
|
Only in amarok-2.5.0.new/src/context/toolbar: AppletToolbar.cpp.orig
|
|
Only in amarok-2.5.0.new/src/context/toolbar: AppletToolbar.cpp.rej
|
|
diff -rup amarok-2.5.0/src/context/toolbar/AppletToolbar.h amarok-2.5.0.new/src/context/toolbar/AppletToolbar.h
|
|
--- amarok-2.5.0/src/context/toolbar/AppletToolbar.h 2011-12-15 08:36:48.000000000 +0100
|
|
+++ amarok-2.5.0.new/src/context/toolbar/AppletToolbar.h 2012-01-29 20:17:52.414686784 +0100
|
|
@@ -55,6 +55,9 @@ class AppletToolbar : public QGraphicsWi
|
|
|
|
void appletRemoved( Plasma::Applet* applet );
|
|
|
|
+ void setContainment( Containment * containment );
|
|
+ Containment* containment() const;
|
|
+
|
|
signals:
|
|
void showApplet( Plasma::Applet* );
|
|
void appletAddedToToolbar( Plasma::Applet* applet, int loc );
|
|
Only in amarok-2.5.0.new/src/context/toolbar: AppletToolbar.h.orig
|
|
diff -rup amarok-2.5.0/src/context/ToolbarView.cpp amarok-2.5.0.new/src/context/ToolbarView.cpp
|
|
--- amarok-2.5.0/src/context/ToolbarView.cpp 2011-12-15 08:36:48.000000000 +0100
|
|
+++ amarok-2.5.0.new/src/context/ToolbarView.cpp 2012-01-29 20:17:52.394686782 +0100
|
|
@@ -74,7 +74,9 @@ Context::ToolbarView::ToolbarView( Plasm
|
|
setVerticalScrollBarPolicy( Qt::ScrollBarAlwaysOff );
|
|
|
|
// now we create the toolbar
|
|
- m_toolbar = new AppletToolbar( containment );
|
|
+ m_toolbar = new AppletToolbar(0);
|
|
+ scene->addItem(m_toolbar.data());
|
|
+ m_toolbar.data()->setContainment( qobject_cast<Context::Containment *>(containment) );
|
|
m_toolbar.data()->setZValue( m_toolbar.data()->zValue() + 1000 );
|
|
m_toolbar.data()->setPos( TOOLBAR_X_OFFSET, 0 );
|
|
|
|
@@ -96,7 +98,7 @@ Context::ToolbarView::ToolbarView( Plasm
|
|
|
|
Context::ToolbarView::~ToolbarView()
|
|
{
|
|
-
|
|
+ delete m_toolbar.data();
|
|
}
|
|
|
|
void
|
|
Only in amarok-2.5.0.new/src/context: ToolbarView.cpp.orig
|