[Pkg-wmaker-commits] [wmmixer] 11/16: Remove trailing whitespace.

Doug Torrance dtorrance-guest at moszumanska.debian.org
Tue Aug 29 09:59:07 UTC 2017


This is an automated email from the git hooks/post-receive script.

dtorrance-guest pushed a commit to branch upstream
in repository wmmixer.

commit 0fcb0a3dfdc8a5454256513e0dc23f7e249be476
Author: Doug Torrance <dtorrance at monmouthcollege.edu>
Date:   Sun Oct 5 10:29:59 2014 -0500

    Remove trailing whitespace.
---
 CHANGES                                       |  2 +-
 debian/changelog                              |  4 +-
 debian/patches/01_debian_paths.patch          |  4 +-
 debian/patches/02_Makefile_optimization.patch |  6 +-
 exception.h                                   |  2 +-
 mixctl.cc                                     |  4 +-
 mixctl.h                                      |  4 +-
 wmmixer.1                                     |  6 +-
 wmmixer.cc                                    | 52 +++++++--------
 xhandler.cc                                   | 92 +++++++++++++--------------
 xhandler.h                                    |  6 +-
 11 files changed, 91 insertions(+), 91 deletions(-)

diff --git a/CHANGES b/CHANGES
index d0cc90c..dc0e15b 100644
--- a/CHANGES
+++ b/CHANGES
@@ -67,7 +67,7 @@ Release 1.2   25 May 2002 Merge Debian patches
 
 
 Release 1.3   26 May 2002 Change the whole thing to actual C++ code.
-                          It is not yet pretty code, but it is a lot 
+                          It is not yet pretty code, but it is a lot
                           better. Still, much work to do.
 
 Release 1.4   08 Jun 2002 Display only one bar for mono channels
diff --git a/debian/changelog b/debian/changelog
index e869521..2069fbb 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -110,7 +110,7 @@ wmmixer (1.5-7) unstable; urgency=low
 wmmixer (1.5-6.1) unstable; urgency=low
 
   * Porter NMU.
-  * Added support for GNU/kFreeBSD (Closes: #332992). 
+  * Added support for GNU/kFreeBSD (Closes: #332992).
 
  -- Aurelien Jarno <aurel32 at debian.org>  Sun, 10 Dec 2006 21:45:54 +0100
 
@@ -201,7 +201,7 @@ wmmixer (1.1-3) unstable; urgency=low
 
 wmmixer (1.1-2) unstable; urgency=low
 
-  * Correct Makefile to use C++ compiler instead of C compiler 
+  * Correct Makefile to use C++ compiler instead of C compiler
     (Closes: #141696)
 
  -- Gordon Fraser <gordon at debian.org>  Mon,  8 Apr 2002 09:00:48 +0200
diff --git a/debian/patches/01_debian_paths.patch b/debian/patches/01_debian_paths.patch
index f89d000..826a6a2 100644
--- a/debian/patches/01_debian_paths.patch
+++ b/debian/patches/01_debian_paths.patch
@@ -5,13 +5,13 @@ Last-Update: 2007-10-08
 +++ b/Makefile
 @@ -1,12 +1,10 @@
  # $Id: Makefile,v 1.5 2002/06/25 22:13:09 gordon Exp $
- 
+
 -prefix      = /usr/local
 +prefix      = /usr
  exec_prefix = ${prefix}
  bindir      = ${exec_prefix}/bin
  mandir      = ${prefix}/share/man
- 
+
 -DESTDIR     =
 -
  CXX	    = g++
diff --git a/debian/patches/02_Makefile_optimization.patch b/debian/patches/02_Makefile_optimization.patch
index 260b175..d992010 100644
--- a/debian/patches/02_Makefile_optimization.patch
+++ b/debian/patches/02_Makefile_optimization.patch
@@ -5,7 +5,7 @@ Last-Update: 2007-10-08
 +++ b/Makefile
 @@ -6,7 +6,14 @@
  mandir      = ${prefix}/share/man
- 
+
  CXX	    = g++
 -CXXFLAGS    = -O -Wall
 +CXXFLAGS    = -Wall -g
@@ -17,5 +17,5 @@ Last-Update: 2007-10-08
 +endif
 +
  EXTRA_LIBS  = -L/usr/X11R6/lib -lX11 -lXpm -lXext
- 
- 
+
+
diff --git a/exception.h b/exception.h
index 4c8a138..eee481e 100644
--- a/exception.h
+++ b/exception.h
@@ -20,7 +20,7 @@ class Exception
 {
  protected:
   char* error_message_;
-  
+
  public:
   Exception();
   Exception(const Exception&);
diff --git a/mixctl.cc b/mixctl.cc
index 10a40b3..ffea52c 100644
--- a/mixctl.cc
+++ b/mixctl.cc
@@ -245,12 +245,12 @@ bool MixCtl::hasChanged()
 {
   struct mixer_info mixer_info1;
   ioctl(mixfd, SOUND_MIXER_INFO, &mixer_info1);
-     
+
   if (mixer_info1.modify_counter == modify_counter)
     {
       return false;
     }
-  else 
+  else
     {
       modify_counter = mixer_info1.modify_counter;
       return true;
diff --git a/mixctl.h b/mixctl.h
index 1783dc4..44d8251 100644
--- a/mixctl.h
+++ b/mixctl.h
@@ -47,7 +47,7 @@ struct _MixerDevice_{
   int mask;
   int muted;
 };
-  
+
 typedef struct _MixerDevice_ MixerDevice;
 
 //----------------------------------------------------------------------
@@ -69,7 +69,7 @@ class MixCtl
   MixerDevice* mixer_devices_;
 
   void doStatus();
-  
+
  public:
   MixCtl(char *dname) throw(MixerDeviceException);
   virtual ~MixCtl();
diff --git a/wmmixer.1 b/wmmixer.1
index 4d26c51..fc4c90e 100644
--- a/wmmixer.1
+++ b/wmmixer.1
@@ -1,7 +1,7 @@
-.TH wmmixer 1 "April 02, 2002" Debian "Windowmaker Mixer Application" 
+.TH wmmixer 1 "April 02, 2002" Debian "Windowmaker Mixer Application"
 
 .SH NAME
-wmmixer \- A mixer application designed for WindowMaker 
+wmmixer \- A mixer application designed for WindowMaker
 .SH DESCRIPTION
 \fBwmmixer\fP is a mixer application designed for WindowMaker, although
 there is nothing in the program that makes it require WindowMaker, except
@@ -11,7 +11,7 @@ properly docks. It can be used with other window managers without problems.
 .B wmmixer [options]
 .SH OPTIONS
 This program follows the usual GNU command line syntax, with long options
-starting with two dashes ('\-\-'). A summary of options is included below. 
+starting with two dashes ('\-\-'). A summary of options is included below.
 .TP
 .B \-d,  \-\-display <\fIstring\fP>
 Attempt to open a window on the named X display. In the absence of  this
diff --git a/wmmixer.cc b/wmmixer.cc
index 7804aea..15bef43 100644
--- a/wmmixer.cc
+++ b/wmmixer.cc
@@ -45,14 +45,14 @@ WMMixer::~WMMixer()
 void WMMixer::loop()
 {
   XEvent xev;
-  
+
   bool done=false;
   while(!done)
     {
-      while(XPending(xhandler_->getDisplay())) 
+      while(XPending(xhandler_->getDisplay()))
 	{
 	  XNextEvent(xhandler_->getDisplay(), &xev);
-	  switch(xev.type) 
+	  switch(xev.type)
 	    {
 	    case Expose:
 	      xhandler_->repaint();
@@ -72,7 +72,7 @@ void WMMixer::loop()
 	      break;
 	    }
 	}
-            
+
       // keep a button pressed causes scrolling throught the channels
       if(xhandler_->getButtonState() & (BTNPREV | BTNNEXT))
 	{
@@ -97,11 +97,11 @@ void WMMixer::loop()
 	      repeat_timer_ = 0;
 	    }
 	}
-      else 
+      else
 	{
 	  checkVol(false);
 	}
-      
+
       XFlush(xhandler_->getDisplay());
       usleep(100000);
     }
@@ -115,7 +115,7 @@ void WMMixer::init(int argc, char **argv)
 
   initMixer();
 
-  readConfigurationFile(); 
+  readConfigurationFile();
 
   xhandler_->init(argc, argv, mixctl_->getNrDevices());
 
@@ -144,7 +144,7 @@ void WMMixer::initMixer()
     }
 
   channel_list_ = new unsigned[mixctl_->getNrDevices()];
-  
+
   for(unsigned count=0; count<mixctl_->getNrDevices(); count++)
     {
       if(mixctl_->getSupport(count)){
@@ -214,7 +214,7 @@ void WMMixer::checkVol(bool forced = true)
 	      xhandler_->drawBtns(BTNREC, current_show_recording_);
 	    }
 	  updateDisplay();
-	}      
+	}
     }
 }
 
@@ -245,17 +245,17 @@ void WMMixer::parseArgs(int argc, char **argv)
   snprintf(config_file_, CONFIGFILELEN -1, "%s/.wmmixer", getenv("HOME"));
 
   // For backward compatibility
-  for(i=1; i<argc; i++) 
+  for(i=1; i<argc; i++)
     {
-      if(strcmp("-position", argv[i]) == 0) 
+      if(strcmp("-position", argv[i]) == 0)
 	{
 	  sprintf(argv[i], "%s", "-g");
-	} 
-      else if(strcmp("-help", argv[i]) == 0) 
+	}
+      else if(strcmp("-help", argv[i]) == 0)
 	{
 	  sprintf(argv[i], "%s", "-h");
-	} 
-      else if(strcmp("-display", argv[i]) == 0) 
+	}
+      else if(strcmp("-display", argv[i]) == 0)
 	{
 	  sprintf(argv[i], "%s", "-d");
 	}
@@ -263,7 +263,7 @@ void WMMixer::parseArgs(int argc, char **argv)
 
   while ((i = getopt_long(argc, argv, "hvd:g:wasl:L:b:m:c:x:r:", long_opts, &opt_index)) != -1)
     {
-      switch (i) 
+      switch (i)
 	{
 	case 'h':
 	case ':':
@@ -398,7 +398,7 @@ void WMMixer::readConfigurationFile()
                   mixctl_->setRec(current, (strncmp(buf+strlen("setrecsrc "), "true", strlen("true"))==0));
 	      }
 	     }
-	 }  
+	 }
        while(done==0);
        fclose(rcfile);
        mixctl_->writeRec();
@@ -441,7 +441,7 @@ void WMMixer::displayVersion()
 
 
 //--------------------------------------------------------------------
-void WMMixer::pressEvent(XButtonEvent *xev) 
+void WMMixer::pressEvent(XButtonEvent *xev)
 {
   bool forced_update = true;
   int x = xev->x-(xhandler_->getWindowSize()/2-32);
@@ -475,19 +475,19 @@ void WMMixer::pressEvent(XButtonEvent *xev)
     {
       int vl = 0, vr = 0;
 
-      if(xev->button < 4) 
+      if(xev->button < 4)
 	{
 	  vl = ((60-y)*100)/(2*25);
 	  vr = vl;
 	  dragging_ = true;
-	} 
-      else if(xev->button == 4) 
+	}
+      else if(xev->button == 4)
 	{
 	  vr = mixctl_->readRight(channel_list_[current_channel_]) + wheel_scroll_;
 	  vl = mixctl_->readLeft(channel_list_[current_channel_])  + wheel_scroll_;
-	  
-	} 
-      else if(xev->button == 5) 
+
+	}
+      else if(xev->button == 5)
 	{
 	  vr = mixctl_->readRight(channel_list_[current_channel_]) - wheel_scroll_;
 	  vl = mixctl_->readLeft(channel_list_[current_channel_])  - wheel_scroll_;
@@ -503,7 +503,7 @@ void WMMixer::pressEvent(XButtonEvent *xev)
       if(x >= 45)
 	mixctl_->setRight(channel_list_[current_channel_], vr);
       mixctl_->writeVol(channel_list_[current_channel_]);
-      
+
       forced_update = false;
     }
 
@@ -568,7 +568,7 @@ void WMMixer::motionEvent(XMotionEvent *xev)
 void WMMixer::updateDisplay()
 {
   xhandler_->update(channel_list_[current_channel_]);
-  if(mixctl_->getStereo(channel_list_[current_channel_])) 
+  if(mixctl_->getStereo(channel_list_[current_channel_]))
     {
       xhandler_->drawLeft(current_channel_left_);
       xhandler_->drawRight(current_channel_right_);
diff --git a/xhandler.cc b/xhandler.cc
index 506bf18..95d76a2 100644
--- a/xhandler.cc
+++ b/xhandler.cc
@@ -45,24 +45,24 @@ XHandler::~XHandler()
     XDestroyWindow(display_default_, window_icon_);
 
   XCloseDisplay(display_default_);
-  
+
   delete[] icon_list_;
 }
 
 
 //--------------------------------------------------------------------
 void XHandler::init(int argc, char** argv, int num_channels)
-{    
+{
   int display_depth;
 
   window_size_=is_astep_ ? ASTEPSIZE : NORMSIZE;
-  
-  if((display_default_ = XOpenDisplay(display_name_))==NULL) 
+
+  if((display_default_ = XOpenDisplay(display_name_))==NULL)
     {
       std::cerr <<  NAME << " : Unable to open X display '" << XDisplayName(display_name_) << "'." << std::endl;
       exit(1);
     }
-  
+
   initWindow(argc, argv);
 
   initColors();
@@ -146,30 +146,30 @@ unsigned long XHandler::mixColor(char *colorname1, int prop1, char *colorname2,
 }
 
 //--------------------------------------------------------------------
-void XHandler::repaint() 
+void XHandler::repaint()
 {
   flush_expose(window_icon_);
   XCopyArea(display_default_, pixmap_disp, window_icon_, graphics_context_, 0, 0, 64, 64, window_size_/2-32, window_size_/2-32);
   flush_expose(window_main_);
   XCopyArea(display_default_, pixmap_disp, window_main_, graphics_context_, 0, 0, 64, 64, window_size_/2-32, window_size_/2-32);
-  
+
   XEvent xev;
   while(XCheckTypedEvent(display_default_, Expose, &xev));
 }
 
 //--------------------------------------------------------------------
-void XHandler::update(unsigned channel) 
+void XHandler::update(unsigned channel)
 {
-  if(is_wmaker_ || is_ushape_ || is_astep_) 
+  if(is_wmaker_ || is_ushape_ || is_astep_)
     {
       XShapeCombineMask(display_default_, window_icon_, ShapeBounding, window_size_/2-32, window_size_/2-32, pixmap_mask, ShapeSet);
       XShapeCombineMask(display_default_, window_main_, ShapeBounding, window_size_/2-32, window_size_/2-32, pixmap_mask, ShapeSet);
-    } 
-  else 
+    }
+  else
     {
       XCopyArea(display_default_, pixmap_tile, pixmap_disp, graphics_context_, 0, 0, 64, 64, 0, 0);
     }
-  
+
   XSetClipMask(display_default_, graphics_context_, pixmap_mask);
   XCopyArea(display_default_, pixmap_main, pixmap_disp, graphics_context_, 0, 0, 64, 64, 0, 0);
   XSetClipMask(display_default_, graphics_context_, None);
@@ -177,7 +177,7 @@ void XHandler::update(unsigned channel)
 }
 
 //--------------------------------------------------------------------
-void XHandler::drawLeft(unsigned curleft) 
+void XHandler::drawLeft(unsigned curleft)
 {
   XSetForeground(display_default_, graphics_context_, shade_colors_[(curleft*25)/100]);
   for(unsigned i=0;i<25;i++)
@@ -195,7 +195,7 @@ void XHandler::drawLeft(unsigned curleft)
 }
 
 //--------------------------------------------------------------------
-void XHandler::drawRight(unsigned curright) 
+void XHandler::drawRight(unsigned curright)
 {
   for(unsigned i=0;i<25;i++)
     {
@@ -232,7 +232,7 @@ void XHandler::drawMono(unsigned curright)
 
 
 //--------------------------------------------------------------------
-void XHandler::drawBtns(int buttons, bool curshowrec) 
+void XHandler::drawBtns(int buttons, bool curshowrec)
 {
   if(buttons & BTNPREV)
     drawButton(BTN_LEFT_X, BTN_LEFT_Y, BTN_WIDTH, BTN_HEIGHT, (button_state_ & BTNPREV));
@@ -245,7 +245,7 @@ void XHandler::drawBtns(int buttons, bool curshowrec)
 
   if(buttons & BTNREC){
     drawButton(BTN_REC_X, BTN_REC_Y, BTN_WIDTH, BTN_HEIGHT, (button_state_ & BTNREC));
-    
+
     if(!curshowrec)
       XCopyArea(display_default_, pixmap_nrec, pixmap_disp, graphics_context_, 0, 0, 9, 8, 6, 47);
     else
@@ -254,7 +254,7 @@ void XHandler::drawBtns(int buttons, bool curshowrec)
 }
 
 //--------------------------------------------------------------------
-void XHandler::drawButton(int x, int y, int w, int h, bool down) 
+void XHandler::drawButton(int x, int y, int w, int h, bool down)
 {
   if(!down)
     XCopyArea(display_default_, pixmap_main, pixmap_disp, graphics_context_, x, y, w, h, x, y);
@@ -267,14 +267,14 @@ void XHandler::drawButton(int x, int y, int w, int h, bool down)
 }
 
 //--------------------------------------------------------------------
-int XHandler::flush_expose(Window w) 
+int XHandler::flush_expose(Window w)
 {
   XEvent dummy;
   int i=0;
-  
+
   while (XCheckTypedWindowEvent(display_default_, w, Expose, &dummy))
     i++;
-  
+
   return i;
 }
 
@@ -367,13 +367,13 @@ Atom XHandler::getDeleteWin()
 
 
 //--------------------------------------------------------------------
-void XHandler::initIcons(int num) 
+void XHandler::initIcons(int num)
 {
   if(icon_list_)
     delete[] icon_list_;
-  
+
   icon_list_ = new unsigned[num];
-  
+
   icon_list_[0] = 0;
   icon_list_[1] = 7;
   icon_list_[2] = 8;
@@ -397,7 +397,7 @@ void XHandler::initGraphicsContext()
   gcv.graphics_exposures = 0;
   gcv.foreground = fore_pix;
   gcv.background = back_pix;
-  graphics_context_ = XCreateGC(display_default_, window_root_, gcm, &gcv);  
+  graphics_context_ = XCreateGC(display_default_, window_root_, gcm, &gcv);
 }
 
 //--------------------------------------------------------------------
@@ -414,7 +414,7 @@ void XHandler::initPixmaps(int display_depth)
   xpmattr.exactColors  = false;
   xpmattr.closeness    = 40000;
   xpmattr.valuemask    = XpmColorSymbols | XpmExactColors | XpmCloseness;
-  
+
   XpmCreatePixmapFromData(display_default_, window_root_, (char **)wmmixer_xpm, &pixmap_main, &pixmap_mask, &xpmattr);
   XpmCreatePixmapFromData(display_default_, window_root_, (char **)tile_xpm, &pixmap_tile, NULL, &xpmattr);
   XpmCreatePixmapFromData(display_default_, window_root_, (char **)icons_xpm, &pixmap_icon, NULL, &xpmattr);
@@ -443,7 +443,7 @@ void XHandler::initWindow(int argc, char** argv)
   shints.y = 0;
   //  shints.flags  = USSize;
   shints.flags  = 0; // Gordon
-  
+
   bool pos = (XWMGeometry(display_default_, DefaultScreen(display_default_),
 			  position_name_, NULL, 0, &shints, &shints.x, &shints.y,
 			  &shints.width, &shints.height, &dummy)
@@ -466,16 +466,16 @@ void XHandler::initWindow(int argc, char** argv)
 
   window_main_ = XCreateSimpleWindow(display_default_, window_root_, shints.x, shints.y,
 			    shints.width, shints.height, 0, fore_pix, back_pix);
-  
+
   window_icon_ = XCreateSimpleWindow(display_default_, window_root_, shints.x, shints.y,
 				shints.width, shints.height, 0, fore_pix, back_pix);
-  
+
   XSetWMNormalHints(display_default_, window_main_, &shints);
-  
-  
+
+
   wmhints.icon_x = shints.x;
   wmhints.icon_y = shints.y;
-  
+
   if(is_wmaker_ || is_astep_ || pos)
     shints.flags |= USPosition;
 
@@ -484,30 +484,30 @@ void XHandler::initWindow(int argc, char** argv)
       wmhints.initial_state = WithdrawnState;
       wmhints.flags = StateHint | IconWindowHint | IconPositionHint | WindowGroupHint;
       wmhints.icon_window = window_icon_;
-      
+
       wmhints.icon_x = shints.x;
       wmhints.icon_y = shints.y;
       wmhints.window_group = window_main_;
-    } 
-  else 
+    }
+  else
     {
       wmhints.initial_state = NormalState;
       wmhints.flags = WindowGroupHint | StateHint;
     }
-  
+
   classHint.res_name=(char *)NAME;
   classHint.res_class = window_class_;
-  
+
   XSetClassHint(display_default_, window_main_, &classHint);
   XSetClassHint(display_default_, window_icon_, &classHint);
-   
-  
+
+
   if (XStringListToTextProperty(&wname, 1, &name) == 0)
     {
       std::cerr << wname << ": can't allocate window name" << std::endl;
       exit(1);
     }
-  
+
   XSetWMName(display_default_, window_main_, &name);
   XSetWMHints(display_default_, window_main_, &wmhints);
   XSetCommand(display_default_, window_main_, argv, argc);
@@ -518,7 +518,7 @@ void XHandler::initWindow(int argc, char** argv)
 //--------------------------------------------------------------------
 // Initialize main colors and shaded color-array for bars
 void XHandler::initColors()
-{    
+{
   colors_[0] = mixColor(ledcolor_name_, 0,   backcolor_name_, 100);
   colors_[1] = mixColor(ledcolor_name_, 100, backcolor_name_, 0);
   colors_[2] = mixColor(ledcolor_name_, 60,  backcolor_name_, 40);
@@ -533,23 +533,23 @@ void XHandler::initColors()
 
 //--------------------------------------------------------------------
 void XHandler::initMask()
-{    
+{
   XSetClipMask(display_default_, graphics_context_, pixmap_mask);
   XCopyArea(   display_default_, pixmap_main, pixmap_disp, graphics_context_, 0, 0, 64, 64, 0, 0);
   XSetClipMask(display_default_, graphics_context_, None);
   XStoreName(  display_default_, window_main_, NAME);
-  XSetIconName(display_default_, window_main_, NAME); 
+  XSetIconName(display_default_, window_main_, NAME);
 
-  if(is_wmaker_ || is_ushape_ || is_astep_) 
+  if(is_wmaker_ || is_ushape_ || is_astep_)
     {
       XShapeCombineMask(display_default_, window_icon_, ShapeBounding, window_size_/2-32, window_size_/2-32, pixmap_mask, ShapeSet);
       XShapeCombineMask(display_default_, window_main_, ShapeBounding, window_size_/2-32, window_size_/2-32, pixmap_mask, ShapeSet);
-    } 
-  else 
+    }
+  else
     {
       XCopyArea(display_default_, pixmap_tile, pixmap_disp, graphics_context_, 0, 0, 64, 64, 0, 0);
     }
-  
+
   XSelectInput(display_default_, window_main_, ButtonPressMask | ExposureMask | ButtonReleaseMask | PointerMotionMask | StructureNotifyMask);
   XSelectInput(display_default_, window_icon_, ButtonPressMask | ExposureMask | ButtonReleaseMask | PointerMotionMask | StructureNotifyMask);
   XMapWindow(display_default_, window_main_);
diff --git a/xhandler.h b/xhandler.h
index 8dcebf8..e6c9fc4 100644
--- a/xhandler.h
+++ b/xhandler.h
@@ -95,7 +95,7 @@ class XHandler
   Pixmap pixmap_tile;
   Pixmap pixmap_disp;
   Pixmap pixmap_mask;
-  
+
   // Pixmaps - custom
   Pixmap pixmap_icon;
   Pixmap pixmap_nrec;
@@ -103,7 +103,7 @@ class XHandler
   // X-Windows basics - standard
   Atom _XA_GNUSTEP_WM_FUNC;
   Atom deleteWin;
-  
+
 
   unsigned long getColor(char*);
   unsigned long mixColor(char*, int, char*, int);
@@ -128,7 +128,7 @@ class XHandler
   void drawRight(unsigned);
   void drawBtns(int, bool);
   void drawMono(unsigned);
-  
+
   bool isLeftButton(int, int);
   bool isRightButton(int, int);
   bool isMuteButton(int, int);

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-wmaker/wmmixer.git



More information about the Pkg-wmaker-commits mailing list