[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: extragear/multimedia/amarok/src
From: Mike Diehl <madpenguin8 () yahoo ! com>
Date: 2005-08-26 20:53:04
Message-ID: 1125089584.793268.30842.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 453695 by mdiehl:
Remember mount commands.
M +11 -0 amarokcore/amarok.kcfg
M +18 -6 mediabrowser.cpp
M +1 -0 mediabrowser.h
--- trunk/extragear/multimedia/amarok/src/amarokcore/amarok.kcfg #453694:453695
@@ -503,4 +503,15 @@
</entry>
</group>
+<group name="MediaDevice">
+ <entry key="MountCommand" type="String">
+ <label>MountCommand</label>
+ <whatsthis>The mount command used for the media device connection.</whatsthis>
+ </entry>
+ <entry key="UmountCommand" type="String">
+ <label>UmountCommand</label>
+ <whatsthis>The umount command used for the media device connection.</whatsthis>
+ </entry>
+</group>
+
</kcfg>
--- trunk/extragear/multimedia/amarok/src/mediabrowser.cpp #453694:453695
@@ -61,6 +61,10 @@
{
setSpacing( 4 );
+ KToolBar* toolbar = new Browser::ToolBar( this );
+ KToolBarButton *config = new KToolBarButton( "configure", 0, toolbar );
+ QToolTip::add( config, i18n( "Configure media device" ) );
+
{ //<Search LineEdit>
KToolBar* searchToolBar = new Browser::ToolBar( this );
KToolBarButton *button = new KToolBarButton( "locationbar_erase", 0, searchToolBar );
@@ -77,10 +81,11 @@
m_view = new MediaDeviceView( this );
+ connect( config, SIGNAL( clicked() ), MediaDevice::instance(), SLOT( config() ) );
+
setFocusProxy( m_view ); //default object to get focus
}
-
MediaBrowser::~MediaBrowser()
{
delete m_view;
@@ -443,8 +448,8 @@
openIPod();
- //m_mntcmd = "mount /mnt/ipod";
- //m_umntcmd = "umount /mnt/ipod";
+ m_mntcmd = AmarokConfig::mountCommand();
+ m_umntcmd = AmarokConfig::umountCommand();
}
void
@@ -597,14 +602,21 @@
return items;
}
+void
+MediaDevice::config()
+{
+}
+
void MediaDevice::setMountCommand(const QString & mnt)
{
- m_mntcmd=mnt;
+ AmarokConfig::setMountCommand( mnt );
+ m_mntcmd = mnt; //Update for mount()
}
void MediaDevice::setUmountCommand(const QString & umnt)
{
- m_umntcmd=umnt;
+ AmarokConfig::setUmountCommand( umnt);
+ m_umntcmd = umnt; //Update for umount()
}
int MediaDevice::mount()
@@ -697,7 +709,7 @@
else
debug() << "iPod inconsistent!" << endl;
- m_parent->m_transferButton->setEnabled( true );
+ m_parent->m_transferButton->setEnabled( false );
}
--- trunk/extragear/multimedia/amarok/src/mediabrowser.h #453694:453695
@@ -137,6 +137,7 @@
static MediaDevice *instance() { return s_instance; }
public slots:
+ void config();
void setMountCommand(const QString & mnt);
void setUmountCommand(const QString & umnt);
int mount();
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic