cvs commit: patches/kdemultimedia kdemultimedia-3.1.4-kmix-alsa.patch

tushar at linuxfromscratch.org tushar at linuxfromscratch.org
Sun Sep 28 08:58:39 PDT 2003


tushar      03/09/28 09:58:39

  Added:       kdebase  kdebase-3.1.4-kwrited.patch
                        kdebase-3.1.4-rundialog.patch
                        kdebase-3.1.4-smbmount.patch
               kdelibs  kdelibs-3.1.4-ibm866.patch
                        kdelibs-3.1.4-kate-bug55484.patch
               kdemultimedia kdemultimedia-3.1.4-kmix-alsa.patch
  Log:
  Added kde patches
  
  Revision  Changes    Path
  1.1                  patches/kdebase/kdebase-3.1.4-kwrited.patch
  
  Index: kdebase-3.1.4-kwrited.patch
  ===================================================================
  Submitted by: Alexander E. Patrakov (semzx at newmail dot ru)
  Origin: Alexander E. Patrakov
  Date: 2003-09-28
  Initial Package Version: KDE 3.1.3
  Description: Allows the user to copy text from kwrited message window
  and clear that window. Fixes a FIXME.
  Applies to only those people who have the "utempter" program.
  
  diff -ur kdebase-3.1.4/konsole/konsole/kwrited.cpp kdebase-3.1.4.tweaked/konsole/konsole/kwrited.cpp
  --- kdebase-3.1.4/konsole/konsole/kwrited.cpp	2003-05-07 17:44:16.000000000 +0600
  +++ kdebase-3.1.4.tweaked/konsole/konsole/kwrited.cpp	2003-09-28 14:56:46.000000000 +0600
  @@ -41,7 +41,7 @@
     wid->setFont(KGlobalSettings::fixedFont());
     wid->setMinimumWidth(wid->fontMetrics().maxWidth()*80 +
         wid->minimumSizeHint().width());
  -  wid->setReadOnly(true);
  +  wid->setReadOnly(false);
     wid->setFocusPolicy(QWidget::NoFocus);
   
     pty = new TEPty();
  @@ -75,6 +75,9 @@
     // Remove CR
     while ( (i = str.find('\r')) != -1)
        str.remove(i,1);
  +  // Remove BEL
  +  while ( (i = str.find('\a')) != -1)
  +     str.remove(i,1);
     wid->insert( str );
     wid->show();
     XRaiseWindow( wid->x11Display(), wid->winId());
  
  
  
  1.1                  patches/kdebase/kdebase-3.1.4-rundialog.patch
  
  Index: kdebase-3.1.4-rundialog.patch
  ===================================================================
  Submitted by: Alexander E. Patrakov (semzx at newmail dot ru)
  Origin: Alexander E. Patrakov
  Date: 2003-09-28
  Initial Package Version: KDE 3.1.4
  Description: When kdebase is compiled against Qt 3.2.x, the "Run Command"
  dialog has wrong size (looks like the bottom is cut). This patch fixes
  this problem. Don't ask me how it works - I just noticed that in KDE CVS HEAD
  QVBoxLayout is used instead of QGridLayout. Maybe this is a bug in Qt.
  Applies to only those people who built Qt 3.2.x.
  
  
  diff -ur kdebase-3.1.4.orig/kdesktop/minicli.cpp kdebase-3.1.4/kdesktop/minicli.cpp
  --- kdebase-3.1.4.orig/kdesktop/minicli.cpp	2003-09-01 17:31:16.000000000 +0600
  +++ kdebase-3.1.4/kdesktop/minicli.cpp	2003-09-28 20:37:27.000000000 +0600
  @@ -51,8 +51,8 @@
   Minicli::Minicli( QWidget *parent, const char *name)
           :KDialog( parent, name )
   {
  -    m_vbox = new QGridLayout( this, 4, 1, KDialog::marginHint(),
  -                                         KDialog::spacingHint() );
  +    m_vbox = new QVBoxLayout( this, KDialog::marginHint(),
  +                              KDialog::spacingHint() );
       m_vbox->setResizeMode( QLayout::Fixed );
       KWin::setIcons( winId(), DesktopIcon("run"), SmallIcon("run") );
       setCaption( i18n("Run Command") );
  diff -ur kdebase-3.1.4.orig/kdesktop/minicli.h kdebase-3.1.4/kdesktop/minicli.h
  --- kdebase-3.1.4.orig/kdesktop/minicli.h	2003-09-01 17:31:17.000000000 +0600
  +++ kdebase-3.1.4/kdesktop/minicli.h	2003-09-28 20:15:42.000000000 +0600
  @@ -78,7 +78,7 @@
       KURIFilterData* m_filterData;
       QWidget* m_FocusWidget;
       QPushButton* m_btnRun;
  -    QGridLayout *m_vbox;
  +    QVBoxLayout *m_vbox;
       QStringList terminalAppList;
   
       QStringList middleFilters;
  
  
  
  1.1                  patches/kdebase/kdebase-3.1.4-smbmount.patch
  
  Index: kdebase-3.1.4-smbmount.patch
  ===================================================================
  Submitted by: Alexander E. Patrakov (semzx at newmail dot ru)
  Origin: Alexander E. Patrakov
  Date: 2003-09-27
  Initial Package Version: 3.1.3
  Description: implement the logic in the smb kioslave to make smbmounter from
  kdeaddons work with this kioslave. Earlier it worked with smbro ioslave only.
  Patch also applies to KDE 3.1.4
  Notes:
  1) Sorry for the "char samba3_corrupts_memory_here[4096]" hack.
  Please help debugging.
  2) The password is passed as an argument to smbmount. Beware!
  (This is also true for smbro)
  
  diff -ur kdebase-3.1.4.orig/kioslave/smb/kio_smb.h kdebase-3.1.4/kioslave/smb/kio_smb.h
  --- kdebase-3.1.4.orig/kioslave/smb/kio_smb.h	2003-09-09 00:40:26.000000000 +0600
  +++ kdebase-3.1.4/kioslave/smb/kio_smb.h	2003-09-27 12:51:02.000000000 +0600
  @@ -267,6 +267,7 @@
       void readOutput(KProcess *proc, char *buffer, int buflen);
   
   private:
  +    char samba3_corrupts_memory_here[4096];
       QString mybuf;
   
   };
  diff -ur kdebase-3.1.4.orig/kioslave/smb/kio_smb_mount.cpp kdebase-3.1.4/kioslave/smb/kio_smb_mount.cpp
  --- kdebase-3.1.4.orig/kioslave/smb/kio_smb_mount.cpp	2003-06-24 12:29:58.000000000 +0600
  +++ kdebase-3.1.4/kioslave/smb/kio_smb_mount.cpp	2003-09-27 13:00:31.000000000 +0600
  @@ -54,7 +54,7 @@
            }
   
            if (tmp==3) {
  -             if (!KStandardDirs::makeDir(mountPoint)) {
  +             if (!KStandardDirs::makeDir(mountPoint,0700)) {
                    error(KIO::ERR_COULD_NOT_MKDIR, mountPoint);
                    return;
                }
  @@ -62,11 +62,12 @@
            mybuf.truncate(0);
   
            KProcess proc;
  -         proc << "mount";
  -         proc << "-o guest";
  -         proc << "-t smbfs";
  +         proc << "smbmount";
            proc << remotePath.local8Bit();
            proc << mountPoint.local8Bit();
  +         QString autharg = "-o username=" + user;
  +         autharg += ",password=" + password;
  +         proc << autharg.local8Bit();
            connect(&proc, SIGNAL( receivedStdout(KProcess *, char *, int )),
                    SLOT(readOutput(KProcess *, char *, int)));
   
  @@ -85,47 +86,22 @@
      case 2:
      case 4:
         {
  -/*         QString mountPoint;
  +         QString mountPoint;
            stream >> mountPoint;
  -         ClientProcess proc;
  -         QCStringList args;
  -         args<<mountPoint.local8Bit();
  -         if (!proc.start("smbumount",args))
  +         KProcess proc;
  +         proc<<"smbumount";
  +         proc<<mountPoint.local8Bit();
  +         mybuf.truncate(0);
  +         connect(&proc, SIGNAL( receivedStdout(KProcess *, char *, int )),
  +                 SLOT(readOutput(KProcess *, char *, int)));
  +         if (!proc.start(KProcess::Block, KProcess::AllOutput))
            {
               error( KIO::ERR_CANNOT_LAUNCH_PROCESS, "smbumount"+i18n("\nMake sure that the samba package is installed properly on your system."));
               return;
            }
  -         clearBuffer();
  -         while (1)  //until smbumount exits
  -         {
  -            bool stdoutEvent;
  -            proc.select(1,0,&stdoutEvent);
  -            int exitStatus=proc.exited();
  -            if (exitStatus!=-1)
  -            {
  -               kdDebug(KIO_SMB)<<"Smb::waitUntilStarted() smbclient exited with exitcode "<<exitStatus<<endl;
  -               if (tmp==4)
  -               {
  -                  QDir dir(mountPoint);
  -                  dir.cdUp();
  -                  dir.rmdir(mountPoint);
  -                  QString p=dir.path();
  -                  dir.cdUp();
  -                  dir.rmdir(p);
  -               }
  -               if (exitStatus!=0)
  -               {
  -                  if (m_stdoutSize>0)
  -                     kdDebug(KIO_SMB)<<"Smb::waitUntilStarted(): received: -"<<m_stdoutBuffer<<"-"<<endl;
  -                  error( KIO::ERR_CANNOT_LAUNCH_PROCESS, "smbumount");
  -               }
  -               else
  -                  finished();
  -               return;
  -            }
  -            if (stdoutEvent)
  -               readOutput(proc.fd());
  -               }*/
  +         if (proc.exitStatus() != 0) {
  +             error( KIO::ERR_COULD_NOT_UNMOUNT, mybuf);
  +         }
         }
         break;
      default:
  
  
  
  1.1                  patches/kdelibs/kdelibs-3.1.4-ibm866.patch
  
  Index: kdelibs-3.1.4-ibm866.patch
  ===================================================================
  Submitted By: Alexander E. Patrakov (semzx at newmail dot ru)
  Date: 2003-08-13
  Initial Package Version: 3.1.3
  Origin: Alexander E. Patrakov
  Description: Add support for the old "DOS" IBM-866 charset to KDE.
  Applies to Russians only. Not submitted to the KDE team yet.
  
  diff -ur kdelibs-3.1.3/kdecore/kcharsets.cpp kdelibs-3.1.3.tweaked/kdecore/kcharsets.cpp
  --- kdelibs-3.1.3/kdecore/kcharsets.cpp	2003-07-14 01:27:41.000000000 +0600
  +++ kdelibs-3.1.3.tweaked/kdecore/kcharsets.cpp	2003-08-02 17:46:04.000000000 +0600
  @@ -37,7 +37,7 @@
   
   #include <assert.h>
   
  -#define CHARSETS_COUNT 33
  +#define CHARSETS_COUNT 34
   
   static const char * const language_names[] = {
   	I18N_NOOP( "Other" ),
  @@ -107,6 +107,8 @@
       "tscii",                 "tscii", 0,
       "pt 154",                "pt 154","cp 1251","koi8-u","koi8-r","iso8859-5", 0,
       "winsami2",              "winsami2", "cp1252", "unicode", 0,
  +    "ibm866",               "ibm866","cp 1251","koi8-u","koi8-r","iso8859-5", 0,
  +
       0 }; // extra 0 for end
   
   // 0 other
  @@ -171,6 +173,7 @@
       { "ucs2", 15 },
       { "iso-10646-ucs-2", 15 },
       { "winsami2", 16},
  +    { "ibm866", 6},
       { 0, 0 } };
   
   // defines some different names for codecs that are built into Qt.
  @@ -212,6 +215,8 @@
       { "shift-jis", "sjis" },
       { "x-sjis", "sjis" },
       { "iso-2022-jp", "jis7" },
  +    { "cp 866", "ibm866" },
  +    { "cp-866", "ibm866" },
       { "windows1250", "cp 1250" },
       { "windows1251", "cp 1251" },
       { "windows1252", "cp 1252" },
  
  
  
  1.1                  patches/kdelibs/kdelibs-3.1.4-kate-bug55484.patch
  
  Index: kdelibs-3.1.4-kate-bug55484.patch
  ===================================================================
  Submitted by: Alexander E. Patrakov (semzx at newmail dot ru)
  Date: 2003-08-13
  Initial Package Version: 3.1.3
  Origin: http://bugs.kde.org/show_bug.cgi?id=55484
  Description: Fix the problem "Bug 55484 - Wordwrap doesn't respect
  white space" . To reproduce: type words in Kate, until wordwrap happens
  twice. Add a word to the first line. One of the spaces between
  previously typed words disappears.
  Notes:
  1) This patch should go into the book.
  2) Watch for updated information at http://bugs.kde.org/show_bug.cgi?id=55484 
  since this fix is not 100% correct.
  
  diff -ur kdelibs-3.1.3/kate/part/katedocument.cpp kdelibs-3.1.3.tweaked/kate/part/katedocument.cpp
  --- kdelibs-3.1.3/kate/part/katedocument.cpp	2003-07-14 01:27:37.000000000 +0600
  +++ kdelibs-3.1.3.tweaked/kate/part/katedocument.cpp	2003-07-30 18:16:22.000000000 +0600
  @@ -916,23 +916,41 @@
       {
         const QChar *text = l->text();
   
  -      for (z=col; z>0; z--)
  -      {
  -        if (z < 1) break;
  +      const QChar aSpace = ' ';
  +      uint eolPosition = l->length()-1;
  +      uint searchStart = col;
  +      //If where we are wrapping is an end of line and is a space we don't
  +      //want to wrap there
  +      if (col == eolPosition && text[col].isSpace())
  +       searchStart--;
  +
  +      // Scan backwards looking for a place to break the line
  +      // We are not interested in breaking at the first char
  +      // of the line (if it is a space), but we are at the second
  +      for (z=searchStart; z>0; z--)
           if (text[z].isSpace()) break;
  -      }
   
  -      if (!(z < 1))
  +      if (z > 0)
         {
  +       //We found a space in which to wrap so break just after it
           z++; // (anders: avoid the space at the beginning of the line)
  -        editWrapLine (line, z, true);
  -        endLine++;
  +
  +       // If the last character of the line is not a space, but we
  +        // are going to break on a previous space, then we assume that the
  +        // line is broken into words and we need to add a space so that when th
  +        // back end of the line is inserted into the next line there is
  +        // a word boundary.
  +        if (!text[eolPosition].isSpace())
  +         l->insertText(eolPosition+1,1,&aSpace);
  +
         }
         else
  -      {
  -        editWrapLine (line, col, true);
  -        endLine++;
  -      }
  +       //There was no space to break at so break at full line
  +       //and don't try and add any white space for the break
  +       z= col;
  +
  +      editWrapLine (line, z, true);
  +      endLine++;
       }
   
       line++;
  
  
  
  1.1                  patches/kdemultimedia/kdemultimedia-3.1.4-kmix-alsa.patch
  
  Index: kdemultimedia-3.1.4-kmix-alsa.patch
  ===================================================================
  Submitted By: Alexander E. Patrakov (semzx at newmail dot ru)
  Date: 2003-08-13
  Initial Package Version: 3.1.3
  Origin: Alexander E. Patrakov
  Description: Turn off the magic that kmix does to determine the 
  "master" volume control. Always assume that the zeroth control is 
  the master one. The line that I commented out is certainly incorrect. 
  This "fix" will not be accepted by the KDE team because it's 
  ideologically wrong, but they don't currently have a good one.
  http://bugs.kde.org/show_bug.cgi?id=61905
  
  Applies to owners of FM801-based soundcards, maybe others. You can 
  hard-code the relevant control number in the first m_masterDevice = ... anyway.
  
  diff -ur kdemultimedia-3.1.3/kmix/mixer_alsa9.cpp kdemultimedia-3.1.3.tweaked/kmix/mixer_alsa9.cpp
  --- kdemultimedia-3.1.3/kmix/mixer_alsa9.cpp	2003-05-07 17:46:50.000000000 +0600
  +++ kdemultimedia-3.1.3.tweaked/kmix/mixer_alsa9.cpp	2003-07-31 21:06:57.000000000 +0600
  @@ -60,6 +60,7 @@
   Mixer_ALSA::Mixer_ALSA( int device, int card ) :
   	Mixer( device, card ), handle(0)
   {
  +    m_masterDevice = 0;
   }
   
   Mixer_ALSA::~Mixer_ALSA()
  @@ -70,10 +71,9 @@
   Mixer_ALSA::identify( snd_mixer_selem_id_t *sid )
   {
   	QString name = snd_mixer_selem_id_get_name( sid );
  -
   	if ( name == "Master" )
   	{
  -		m_masterDevice = snd_mixer_selem_id_get_index( sid );
  +//		m_masterDevice = snd_mixer_selem_id_get_index( sid );
   		return MixDevice::VOLUME;
   	}
   	if ( name == "Master Mono" ) return MixDevice::VOLUME;
  
  
  



More information about the patches mailing list