rename the following methods:

tqparent parent
tqmask mask


git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kradio@1246260 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 13 years ago
parent 2620ed602b
commit de737d3d64

@ -24,8 +24,8 @@
#include <math.h> #include <math.h>
QAlsaMixerElement::QAlsaMixerElement(TQWidget *tqparent, const TQString &label, bool has_switch, bool has_volume) QAlsaMixerElement::QAlsaMixerElement(TQWidget *parent, const TQString &label, bool has_switch, bool has_volume)
: AlsaMixerElementUI(tqparent), : AlsaMixerElementUI(parent),
m_HasVolume(has_volume), m_HasVolume(has_volume),
m_HasSwitch(has_switch), m_HasSwitch(has_switch),
m_dirty(false), m_dirty(false),

@ -25,7 +25,7 @@ class QAlsaMixerElement : public AlsaMixerElementUI
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
QAlsaMixerElement(TQWidget *tqparent, const TQString &label, bool has_switch, bool has_volume); QAlsaMixerElement(TQWidget *parent, const TQString &label, bool has_switch, bool has_volume);
~QAlsaMixerElement(); ~QAlsaMixerElement();

@ -32,8 +32,8 @@
#include "alsa-sound.h" #include "alsa-sound.h"
AlsaSoundConfiguration::AlsaSoundConfiguration (TQWidget *tqparent, AlsaSoundDevice *dev) AlsaSoundConfiguration::AlsaSoundConfiguration (TQWidget *parent, AlsaSoundDevice *dev)
: AlsaSoundConfigurationUI(tqparent), : AlsaSoundConfigurationUI(parent),
m_SoundDevice (dev), m_SoundDevice (dev),
m_groupMixerLayout(NULL), m_groupMixerLayout(NULL),
m_groupMixerScrollView(NULL), m_groupMixerScrollView(NULL),

@ -37,7 +37,7 @@ class AlsaSoundConfiguration : public AlsaSoundConfigurationUI
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
AlsaSoundConfiguration (TQWidget *tqparent, AlsaSoundDevice *); AlsaSoundConfiguration (TQWidget *parent, AlsaSoundDevice *);
~AlsaSoundConfiguration (); ~AlsaSoundConfiguration ();
protected slots: protected slots:

@ -900,7 +900,7 @@ bool AlsaSoundDevice::closeCaptureMixerDevice(bool force)
} }
static int mixer_dummy_callback(snd_mixer_t *, unsigned int /*tqmask*/, snd_mixer_elem_t */*elem*/) static int mixer_dummy_callback(snd_mixer_t *, unsigned int /*mask*/, snd_mixer_elem_t */*elem*/)
{ {
return 0; return 0;
} }

@ -26,8 +26,8 @@
using namespace std; using namespace std;
DockingConfiguration::DockingConfiguration (RadioDocking *docking, TQWidget *tqparent) DockingConfiguration::DockingConfiguration (RadioDocking *docking, TQWidget *parent)
: StationSelector(tqparent), : StationSelector(parent),
m_docking(docking), m_docking(docking),
m_disableGUIUpdates(false) m_disableGUIUpdates(false)
{ {

@ -33,7 +33,7 @@ class DockingConfiguration : public StationSelector
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
DockingConfiguration (RadioDocking *docking, TQWidget *tqparent); DockingConfiguration (RadioDocking *docking, TQWidget *parent);
~DockingConfiguration (); ~DockingConfiguration ();
protected slots: protected slots:

@ -56,9 +56,9 @@ TQLayoutItem *ButtonFlowLayoutIterator::takeCurrent()
/**************************************************************/ /**************************************************************/
ButtonFlowLayout::ButtonFlowLayout( TQWidget *tqparent, int margin, int spacing, ButtonFlowLayout::ButtonFlowLayout( TQWidget *parent, int margin, int spacing,
const char *name ) const char *name )
: TQLayout( tqparent, margin, spacing, name ), : TQLayout( parent, margin, spacing, name ),
cached_width(0) cached_width(0)
{ {
} }

@ -29,7 +29,7 @@
class ButtonFlowLayout : public TQLayout class ButtonFlowLayout : public TQLayout
{ {
public: public:
ButtonFlowLayout( TQWidget *tqparent, int margin = 0, int spacing=-1, ButtonFlowLayout( TQWidget *parent, int margin = 0, int spacing=-1,
const char *name=0 ); const char *name=0 );
ButtonFlowLayout( TQLayout* parentLayout, int spacing=-1, const char *name=0 ); ButtonFlowLayout( TQLayout* parentLayout, int spacing=-1, const char *name=0 );

@ -19,8 +19,8 @@
using namespace std; using namespace std;
QuickbarConfiguration::QuickbarConfiguration (TQWidget *tqparent) QuickbarConfiguration::QuickbarConfiguration (TQWidget *parent)
: StationSelector(tqparent) : StationSelector(parent)
{ {
} }

@ -29,7 +29,7 @@ class QuickbarConfiguration : public StationSelector
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
QuickbarConfiguration (TQWidget *tqparent); QuickbarConfiguration (TQWidget *parent);
~QuickbarConfiguration (); ~QuickbarConfiguration ();
}; };

@ -25,8 +25,8 @@
#include <tqlabel.h> #include <tqlabel.h>
#include <tqbuttongroup.h> #include <tqbuttongroup.h>
DisplayConfiguration::DisplayConfiguration(TQWidget *tqparent) DisplayConfiguration::DisplayConfiguration(TQWidget *parent)
: TQWidget (tqparent), : TQWidget (parent),
m_dirty(true), m_dirty(true),
m_ignore_gui_updates(false) m_ignore_gui_updates(false)
{ {

@ -34,7 +34,7 @@ class DisplayConfiguration : public TQWidget,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
DisplayConfiguration(TQWidget *tqparent); DisplayConfiguration(TQWidget *parent);
~DisplayConfiguration(); ~DisplayConfiguration();
// Interface // Interface

@ -17,8 +17,8 @@
#include "radioview-configuration.h" #include "radioview-configuration.h"
RadioViewConfiguration::RadioViewConfiguration(TQWidget *tqparent) RadioViewConfiguration::RadioViewConfiguration(TQWidget *parent)
: TQTabWidget (tqparent), : TQTabWidget (parent),
m_dirty(true) m_dirty(true)
{ {
} }

@ -31,7 +31,7 @@ class RadioViewConfiguration : public TQTabWidget
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
RadioViewConfiguration(TQWidget *tqparent = NULL); RadioViewConfiguration(TQWidget *parent = NULL);
~RadioViewConfiguration(); ~RadioViewConfiguration();
void addTab (TQWidget *child, const TQString &label); void addTab (TQWidget *child, const TQString &label);

@ -17,7 +17,7 @@
#include "radioview_element.h" #include "radioview_element.h"
RadioViewElement::RadioViewElement (TQWidget * /*tqparent*/, const TQString & /*name*/, RadioViewElement::RadioViewElement (TQWidget * /*parent*/, const TQString & /*name*/,
RadioViewClass cls) RadioViewClass cls)
: myClass(cls) : myClass(cls)
{ {

@ -40,7 +40,7 @@ class RadioViewElement : public TQFrame,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
RadioViewElement (TQWidget *tqparent, const TQString &name, RadioViewClass myClass); RadioViewElement (TQWidget *parent, const TQString &name, RadioViewClass myClass);
virtual ~RadioViewElement(); virtual ~RadioViewElement();
bool connectI (Interface *) { return false; } // default behaviour, please overwrite in derived class bool connectI (Interface *) { return false; } // default behaviour, please overwrite in derived class

@ -25,8 +25,8 @@
#include "radioview_frequencyradio.h" #include "radioview_frequencyradio.h"
#include "displaycfg.h" #include "displaycfg.h"
RadioViewFrequencyRadio::RadioViewFrequencyRadio(TQWidget *tqparent, const TQString &name ) RadioViewFrequencyRadio::RadioViewFrequencyRadio(TQWidget *parent, const TQString &name )
: RadioViewElement(tqparent, name, clsRadioDisplay), : RadioViewElement(parent, name, clsRadioDisplay),
m_power(false), m_power(false),
m_valid(false), m_valid(false),
m_frequency(0), m_frequency(0),

@ -36,7 +36,7 @@ class RadioViewFrequencyRadio : public RadioViewElement, // is a TQObject, must
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
RadioViewFrequencyRadio(TQWidget *tqparent, const TQString &name); RadioViewFrequencyRadio(TQWidget *parent, const TQString &name);
~RadioViewFrequencyRadio(); ~RadioViewFrequencyRadio();
float getUsability (Interface *) const; float getUsability (Interface *) const;
@ -88,7 +88,7 @@ RECEIVERS:
public: public:
void reparent (TQWidget *tqparent, WFlags f, const TQPoint &p, bool showIt = FALSE); void reparent (TQWidget *parent, WFlags f, const TQPoint &p, bool showIt = FALSE);
protected: protected:

@ -27,8 +27,8 @@
#include "radioview_frequencyseeker.h" #include "radioview_frequencyseeker.h"
RadioViewFrequencySeeker::RadioViewFrequencySeeker(TQWidget *tqparent, const TQString &name) RadioViewFrequencySeeker::RadioViewFrequencySeeker(TQWidget *parent, const TQString &name)
: RadioViewElement(tqparent, name, clsRadioSeek), : RadioViewElement(parent, name, clsRadioSeek),
m_btnSearchLeft(NULL), m_btnSearchLeft(NULL),
m_btnStepLeft(NULL), m_btnStepLeft(NULL),
m_btnStepRight(NULL), m_btnStepRight(NULL),

@ -31,7 +31,7 @@ class RadioViewFrequencySeeker : public RadioViewElement, // is a TQObject, mus
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
RadioViewFrequencySeeker(TQWidget *tqparent, const TQString &name); RadioViewFrequencySeeker(TQWidget *parent, const TQString &name);
~RadioViewFrequencySeeker(); ~RadioViewFrequencySeeker();
float getUsability(Interface *) const; float getUsability(Interface *) const;

@ -30,8 +30,8 @@
#define SLIDER_MAXVAL 32768 #define SLIDER_MAXVAL 32768
#define SLIDER_RANGE (SLIDER_MAXVAL - SLIDER_MINVAL) #define SLIDER_RANGE (SLIDER_MAXVAL - SLIDER_MINVAL)
RadioViewVolume::RadioViewVolume(TQWidget *tqparent, const TQString &name) RadioViewVolume::RadioViewVolume(TQWidget *parent, const TQString &name)
: RadioViewElement (tqparent, name, clsRadioSound), : RadioViewElement (parent, name, clsRadioSound),
m_slider(NULL), m_slider(NULL),
m_handlingSlot(false) m_handlingSlot(false)
{ {

@ -36,7 +36,7 @@ class RadioViewVolume : public RadioViewElement, // is a TQObject, must be firs
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
RadioViewVolume(TQWidget *tqparent, const TQString &name); RadioViewVolume(TQWidget *parent, const TQString &name);
~RadioViewVolume(); ~RadioViewVolume();
float getUsability(Interface *) const; float getUsability(Interface *) const;

@ -25,8 +25,8 @@
#include "lircsupport.h" #include "lircsupport.h"
#include "listviewitem_lirc.h" #include "listviewitem_lirc.h"
LIRCConfiguration::LIRCConfiguration (TQWidget *tqparent, LircSupport *dev) LIRCConfiguration::LIRCConfiguration (TQWidget *parent, LircSupport *dev)
: LIRCConfigurationUI(tqparent), : LIRCConfigurationUI(parent),
m_LIRC (dev), m_LIRC (dev),
m_dirty(true), m_dirty(true),
m_ignore_gui_updates(false) m_ignore_gui_updates(false)

@ -31,7 +31,7 @@ class LIRCConfiguration : public LIRCConfigurationUI
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
LIRCConfiguration (TQWidget *tqparent, LircSupport *); LIRCConfiguration (TQWidget *parent, LircSupport *);
~LIRCConfiguration (); ~LIRCConfiguration ();
protected slots: protected slots:

@ -17,8 +17,8 @@
#include "listviewitem_lirc.h" #include "listviewitem_lirc.h"
ListViewItemLirc::ListViewItemLirc(TQListView *tqparent, TQListViewItem *after) ListViewItemLirc::ListViewItemLirc(TQListView *parent, TQListViewItem *after)
: KListViewItem(tqparent, after), : KListViewItem(parent, after),
m_renamingInProcess(-1) m_renamingInProcess(-1)
{ {
} }

@ -29,7 +29,7 @@ class ListViewItemLirc : public TQObject, public KListViewItem
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
ListViewItemLirc(TQListView *tqparent, TQListViewItem *after); ListViewItemLirc(TQListView *parent, TQListViewItem *after);
~ListViewItemLirc(); ~ListViewItemLirc();
bool isRenamingInProcess() const { return m_renamingInProcess >= 0; } bool isRenamingInProcess() const { return m_renamingInProcess >= 0; }

@ -23,8 +23,8 @@
#include "oss-sound-configuration.h" #include "oss-sound-configuration.h"
#include "oss-sound.h" #include "oss-sound.h"
OSSSoundConfiguration::OSSSoundConfiguration (TQWidget *tqparent, OSSSoundDevice *dev) OSSSoundConfiguration::OSSSoundConfiguration (TQWidget *parent, OSSSoundDevice *dev)
: OSSSoundConfigurationUI(tqparent), : OSSSoundConfigurationUI(parent),
m_SoundDevice (dev), m_SoundDevice (dev),
m_dirty(true), m_dirty(true),
m_ignore_gui_updates(false) m_ignore_gui_updates(false)

@ -30,7 +30,7 @@ class OSSSoundConfiguration : public OSSSoundConfigurationUI
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
OSSSoundConfiguration (TQWidget *tqparent, OSSSoundDevice *); OSSSoundConfiguration (TQWidget *parent, OSSSoundDevice *);
~OSSSoundConfiguration (); ~OSSSoundConfiguration ();
protected slots: protected slots:

@ -654,10 +654,10 @@ bool OSSSoundDevice::openDSPDevice(const SoundFormat &format, bool reopen)
// setup buffer, ask for 40ms latency // setup buffer, ask for 40ms latency
int tmp = (400 * m_DSPFormat.frameSize() * m_DSPFormat.m_SampleRate) / 1000; int tmp = (400 * m_DSPFormat.frameSize() * m_DSPFormat.m_SampleRate) / 1000;
int tqmask = -1; for (; tmp; tmp >>= 1) ++tqmask; int mask = -1; for (; tmp; tmp >>= 1) ++mask;
if (tqmask < 8) tqmask = 12; // default 4kB if (mask < 8) mask = 12; // default 4kB
tqmask |= 0x7FFF0000; mask |= 0x7FFF0000;
err |= ioctl (m_DSP_fd, SNDCTL_DSP_SETFRAGMENT, &tqmask); err |= ioctl (m_DSP_fd, SNDCTL_DSP_SETFRAGMENT, &mask);
if (err) if (err)
logError(i18n("Cannot set buffers for %1").tqarg(m_DSPDeviceName)); logError(i18n("Cannot set buffers for %1").tqarg(m_DSPDeviceName));
@ -758,17 +758,17 @@ void OSSSoundDevice::getMixerChannels(int query, TQStringList &retval, TQMap<TQS
} }
if (fd >= 0) { if (fd >= 0) {
int tqmask = 0; int mask = 0;
if ( ioctl(fd, MIXER_READ(query), &tqmask) == 0 ) { if ( ioctl(fd, MIXER_READ(query), &mask) == 0 ) {
for (int i = 0; i < SOUND_MIXER_NRDEVICES; ++i) { for (int i = 0; i < SOUND_MIXER_NRDEVICES; ++i) {
if (tqmask & (1 << i)) { if (mask & (1 << i)) {
static const char *labels[] = SOUND_DEVICE_LABELS; static const char *labels[] = SOUND_DEVICE_LABELS;
retval.append(i18n(labels[i])); retval.append(i18n(labels[i]));
revmap.insert(i18n(labels[i]), i); revmap.insert(i18n(labels[i]), i);
} }
} }
} else { } else {
logError(i18n("OSSSoundDevice::getMixerChannels: Cannot read mixer device tqmask on device %1").tqarg(m_MixerDeviceName)); logError(i18n("OSSSoundDevice::getMixerChannels: Cannot read mixer device mask on device %1").tqarg(m_MixerDeviceName));
} }
} }
if (fd != m_Mixer_fd) if (fd != m_Mixer_fd)

@ -104,7 +104,7 @@ ANSWERS:
// ISoundStreamClient: mixer access // ISoundStreamClient: mixer access
protected: protected:
void getMixerChannels(int query_playback_or_rec_tqmask, TQStringList &retval, TQMap<TQString, int> &revmap) const; void getMixerChannels(int query_playback_or_rec_mask, TQStringList &retval, TQMap<TQString, int> &revmap) const;
ANSWERS: ANSWERS:
const TQStringList &getPlaybackChannels() const; const TQStringList &getPlaybackChannels() const;

@ -48,8 +48,8 @@
#include <kurlrequester.h> #include <kurlrequester.h>
#include <klocale.h> #include <klocale.h>
RadioConfiguration::RadioConfiguration (TQWidget *tqparent, const IErrorLogClient &logger) RadioConfiguration::RadioConfiguration (TQWidget *parent, const IErrorLogClient &logger)
: RadioConfigurationUI(tqparent), : RadioConfigurationUI(parent),
ignoreChanges(false), ignoreChanges(false),
devicePopup(NULL), devicePopup(NULL),
m_logger(logger), m_logger(logger),

@ -39,7 +39,7 @@ class RadioConfiguration : public RadioConfigurationUI,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
RadioConfiguration (TQWidget *tqparent, const IErrorLogClient &m_logger); RadioConfiguration (TQWidget *parent, const IErrorLogClient &m_logger);
~RadioConfiguration (); ~RadioConfiguration ();
bool connectI (Interface *i); bool connectI (Interface *i);

@ -32,11 +32,11 @@
#include <kdeversion.h> #include <kdeversion.h>
#include <klocale.h> #include <klocale.h>
RecordingEncoding::RecordingEncoding(TQObject *tqparent, SoundStreamID ssid, RecordingEncoding::RecordingEncoding(TQObject *parent, SoundStreamID ssid,
const RecordingConfig &cfg, const RadioStation *rs, const RecordingConfig &cfg, const RadioStation *rs,
const TQString &filename) const TQString &filename)
: :
m_parent(tqparent), m_parent(parent),
m_config(cfg), m_config(cfg),
m_RadioStation(rs ? rs->copy() : NULL), m_RadioStation(rs ? rs->copy() : NULL),
m_SoundStreamID(ssid), m_SoundStreamID(ssid),

@ -53,7 +53,7 @@ protected:
class RecordingEncoding : public TQThread class RecordingEncoding : public TQThread
{ {
public: public:
RecordingEncoding(TQObject *tqparent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename); RecordingEncoding(TQObject *parent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename);
virtual ~RecordingEncoding(); virtual ~RecordingEncoding();
void run(); void run();

@ -20,10 +20,10 @@
#include <tqmutex.h> #include <tqmutex.h>
#include <klocale.h> #include <klocale.h>
RecordingEncodingMP3::RecordingEncodingMP3(TQObject *tqparent, SoundStreamID ssid, RecordingEncodingMP3::RecordingEncodingMP3(TQObject *parent, SoundStreamID ssid,
const RecordingConfig &cfg, const RadioStation *rs, const RecordingConfig &cfg, const RadioStation *rs,
const TQString &filename) const TQString &filename)
: RecordingEncoding(tqparent, ssid, cfg, rs, filename) : RecordingEncoding(parent, ssid, cfg, rs, filename)
#ifdef HAVE_LAME #ifdef HAVE_LAME
, ,
m_MP3Buffer(NULL), m_MP3Buffer(NULL),

@ -31,7 +31,7 @@
class RecordingEncodingMP3 : public RecordingEncoding class RecordingEncodingMP3 : public RecordingEncoding
{ {
public: public:
RecordingEncodingMP3(TQObject *tqparent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename); RecordingEncodingMP3(TQObject *parent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename);
virtual ~RecordingEncodingMP3(); virtual ~RecordingEncodingMP3();
bool openOutput(const TQString &outputFile); bool openOutput(const TQString &outputFile);

@ -20,10 +20,10 @@
#include <klocale.h> #include <klocale.h>
#include <stdlib.h> #include <stdlib.h>
RecordingEncodingOgg::RecordingEncodingOgg(TQObject *tqparent, SoundStreamID ssid, RecordingEncodingOgg::RecordingEncodingOgg(TQObject *parent, SoundStreamID ssid,
const RecordingConfig &cfg, const RadioStation *rs, const RecordingConfig &cfg, const RadioStation *rs,
const TQString &filename) const TQString &filename)
: RecordingEncoding(tqparent, ssid, cfg, rs, filename) : RecordingEncoding(parent, ssid, cfg, rs, filename)
#ifdef HAVE_OGG #ifdef HAVE_OGG
, ,
m_OggOutput(NULL), m_OggOutput(NULL),

@ -31,7 +31,7 @@
class RecordingEncodingOgg : public RecordingEncoding class RecordingEncodingOgg : public RecordingEncoding
{ {
public: public:
RecordingEncodingOgg(TQObject *tqparent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename); RecordingEncodingOgg(TQObject *parent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename);
virtual ~RecordingEncodingOgg(); virtual ~RecordingEncodingOgg();
bool openOutput(const TQString &outputFile); bool openOutput(const TQString &outputFile);

@ -20,10 +20,10 @@
#include <klocale.h> #include <klocale.h>
RecordingEncodingPCM::RecordingEncodingPCM(TQObject *tqparent, SoundStreamID ssid, RecordingEncodingPCM::RecordingEncodingPCM(TQObject *parent, SoundStreamID ssid,
const RecordingConfig &cfg, const RadioStation *rs, const RecordingConfig &cfg, const RadioStation *rs,
const TQString &filename) const TQString &filename)
: RecordingEncoding(tqparent, ssid, cfg, rs, filename), : RecordingEncoding(parent, ssid, cfg, rs, filename),
m_output(NULL) m_output(NULL)
{ {
m_config.m_SoundFormat.m_Encoding = "raw"; m_config.m_SoundFormat.m_Encoding = "raw";

@ -29,7 +29,7 @@
class RecordingEncodingPCM : public RecordingEncoding class RecordingEncodingPCM : public RecordingEncoding
{ {
public: public:
RecordingEncodingPCM(TQObject *tqparent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename); RecordingEncodingPCM(TQObject *parent, SoundStreamID id, const RecordingConfig &cfg, const RadioStation *rs, const TQString &filename);
virtual ~RecordingEncodingPCM(); virtual ~RecordingEncodingPCM();
bool openOutput(const TQString &outputFile); bool openOutput(const TQString &outputFile);

@ -27,8 +27,8 @@
#include <ktabwidget.h> #include <ktabwidget.h>
RecordingConfiguration::RecordingConfiguration (TQWidget *tqparent) RecordingConfiguration::RecordingConfiguration (TQWidget *parent)
: RecordingConfigurationUI(tqparent), : RecordingConfigurationUI(parent),
m_dirty(true), m_dirty(true),
m_ignore_gui_updates(false) m_ignore_gui_updates(false)
{ {

@ -82,7 +82,7 @@ class RecordingConfiguration : public RecordingConfigurationUI,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
RecordingConfiguration (TQWidget *tqparent); RecordingConfiguration (TQWidget *parent);
~RecordingConfiguration (); ~RecordingConfiguration ();
// IRecCfgClient // IRecCfgClient

@ -33,8 +33,8 @@
#define BLOCK_W_MIN 10 #define BLOCK_W_MIN 10
#define W_MIN (20 * (BLOCK_W_MIN)) #define W_MIN (20 * (BLOCK_W_MIN))
RecordingDataMonitor::RecordingDataMonitor(TQWidget *tqparent, const char *name) RecordingDataMonitor::RecordingDataMonitor(TQWidget *parent, const char *name)
: TQFrame(tqparent, name), : TQFrame(parent, name),
m_channelsMax(NULL), m_channelsMax(NULL),
m_channelsAvg(NULL), m_channelsAvg(NULL),
m_maxValue(INT_MAX), m_maxValue(INT_MAX),

@ -31,7 +31,7 @@ class RecordingDataMonitor : public TQFrame//,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
RecordingDataMonitor(TQWidget *tqparent, const char *name); RecordingDataMonitor(TQWidget *parent, const char *name);
~RecordingDataMonitor(); ~RecordingDataMonitor();
bool noticeSoundStreamData(SoundStreamID id, bool noticeSoundStreamData(SoundStreamID id,

@ -28,8 +28,8 @@
#include "streaming-configuration.h" #include "streaming-configuration.h"
#include "streaming.h" #include "streaming.h"
StreamingConfiguration::StreamingConfiguration (TQWidget *tqparent, StreamingDevice *streamer) StreamingConfiguration::StreamingConfiguration (TQWidget *parent, StreamingDevice *streamer)
: StreamingConfigurationUI(tqparent), : StreamingConfigurationUI(parent),
m_ignore_updates(false), m_ignore_updates(false),
m_dirty(true), m_dirty(true),
m_StreamingDevice(streamer) m_StreamingDevice(streamer)

@ -52,7 +52,7 @@ class StreamingConfiguration : public StreamingConfigurationUI
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
StreamingConfiguration (TQWidget *tqparent, StreamingDevice *streamer); StreamingConfiguration (TQWidget *parent, StreamingDevice *streamer);
~StreamingConfiguration (); ~StreamingConfiguration ();
protected slots: protected slots:

@ -47,8 +47,8 @@ public:
}; };
TimeControlConfiguration::TimeControlConfiguration (TQWidget *tqparent) TimeControlConfiguration::TimeControlConfiguration (TQWidget *parent)
: TimeControlConfigurationUI(tqparent), : TimeControlConfigurationUI(parent),
ITimeControlClient(), ITimeControlClient(),
IRadioClient(), IRadioClient(),
ignoreChanges(false), ignoreChanges(false),
@ -258,17 +258,17 @@ void TimeControlConfiguration::slotWeekdaysChanged ()
{ {
if (ignoreChanges) return; if (ignoreChanges) return;
int tqmask = 0; int mask = 0;
for (int i = 0; i < 7; ++i) { for (int i = 0; i < 7; ++i) {
if (listWeekdays->isSelected(i)) { if (listWeekdays->isSelected(i)) {
tqmask |= (1 << i); mask |= (1 << i);
} }
} }
int idx = listAlarms->currentItem(); int idx = listAlarms->currentItem();
if (idx >= 0 && (unsigned)idx < alarms.size()) { if (idx >= 0 && (unsigned)idx < alarms.size()) {
Alarm &a = alarms[idx]; Alarm &a = alarms[idx];
a.setWeekdayMask(tqmask); a.setWeekdayMask(mask);
ignoreChanges = true; ignoreChanges = true;
bool oldBlock = listAlarms->signalsBlocked(); bool oldBlock = listAlarms->signalsBlocked();

@ -35,7 +35,7 @@ class TimeControlConfiguration : public TimeControlConfigurationUI,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
TimeControlConfiguration (TQWidget *tqparent); TimeControlConfiguration (TQWidget *parent);
~TimeControlConfiguration (); ~TimeControlConfiguration ();
bool connectI (Interface *i); bool connectI (Interface *i);

@ -36,8 +36,8 @@
#include "timeshifter-configuration.h" #include "timeshifter-configuration.h"
#include "timeshifter.h" #include "timeshifter.h"
TimeShifterConfiguration::TimeShifterConfiguration (TQWidget *tqparent, TimeShifter *shifter) TimeShifterConfiguration::TimeShifterConfiguration (TQWidget *parent, TimeShifter *shifter)
: TimeShifterConfigurationUI(tqparent), : TimeShifterConfigurationUI(parent),
m_ignoreGUIChanges(false), m_ignoreGUIChanges(false),
m_myControlChange(0), m_myControlChange(0),
m_PlaybackMixerHelper(comboPlaybackMixerDevice, StringListHelper::SORT_BY_DESCR), m_PlaybackMixerHelper(comboPlaybackMixerDevice, StringListHelper::SORT_BY_DESCR),

@ -36,7 +36,7 @@ class TimeShifterConfiguration : public TimeShifterConfigurationUI,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
TimeShifterConfiguration (TQWidget *tqparent, TimeShifter *shifter); TimeShifterConfiguration (TQWidget *parent, TimeShifter *shifter);
~TimeShifterConfiguration (); ~TimeShifterConfiguration ();
bool connectI (Interface *i); bool connectI (Interface *i);

@ -39,8 +39,8 @@
#include "v4lradio-configuration.h" #include "v4lradio-configuration.h"
#include "v4lradio.h" #include "v4lradio.h"
V4LRadioConfiguration::V4LRadioConfiguration (TQWidget *tqparent, SoundStreamID ssid) V4LRadioConfiguration::V4LRadioConfiguration (TQWidget *parent, SoundStreamID ssid)
: V4LRadioConfigurationUI(tqparent), : V4LRadioConfigurationUI(parent),
m_SoundStreamID(ssid), m_SoundStreamID(ssid),
m_ignoreGUIChanges(false), m_ignoreGUIChanges(false),
m_myControlChange(0), m_myControlChange(0),

@ -41,7 +41,7 @@ class V4LRadioConfiguration : public V4LRadioConfigurationUI,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
V4LRadioConfiguration (TQWidget *tqparent, SoundStreamID id); V4LRadioConfiguration (TQWidget *parent, SoundStreamID id);
~V4LRadioConfiguration (); ~V4LRadioConfiguration ();
bool connectI (Interface *i); bool connectI (Interface *i);

@ -44,7 +44,7 @@
class KRadioAboutTabWidget : public TQTabWidget class KRadioAboutTabWidget : public TQTabWidget
{ {
public: public:
KRadioAboutTabWidget( TQWidget* tqparent ) : TQTabWidget( tqparent ) {} KRadioAboutTabWidget( TQWidget* parent ) : TQTabWidget( parent ) {}
TQSize tqsizeHint() const { TQSize tqsizeHint() const {
return TQTabWidget::tqsizeHint().expandedTo( tabBar()->tqsizeHint() + TQSize(4,4) ); return TQTabWidget::tqsizeHint().expandedTo( tabBar()->tqsizeHint() + TQSize(4,4) );
} }

@ -18,8 +18,8 @@
#include "include/frequencyseekhelper.h" #include "include/frequencyseekhelper.h"
#include <tqtimer.h> #include <tqtimer.h>
FrequencySeekHelper::FrequencySeekHelper(ISeekRadio &tqparent) FrequencySeekHelper::FrequencySeekHelper(ISeekRadio &parent)
: SeekHelper(tqparent) : SeekHelper(parent)
{ {
m_timer = new TQTimer(this); m_timer = new TQTimer(this);
TQObject::connect (m_timer, TQT_SIGNAL(timeout()), this, TQT_SLOT(step())); TQObject::connect (m_timer, TQT_SIGNAL(timeout()), this, TQT_SLOT(step()));

@ -56,7 +56,7 @@ class KRadioImageTrackLabel : public TQLabel
}; };
public: public:
KRadioImageTrackLabel( TQWidget * tqparent, const char * name=0, WFlags f=0 ); KRadioImageTrackLabel( TQWidget * parent, const char * name=0, WFlags f=0 );
signals: signals:
void mouseTrack( int mode, const TQMouseEvent *e ); void mouseTrack( int mode, const TQMouseEvent *e );
@ -92,7 +92,7 @@ class KRadioAboutWidget : public TQWidget
}; };
public: public:
KRadioAboutWidget(const KAboutData &abtData, int layoutType, TQWidget *tqparent = 0, char *name = 0); KRadioAboutWidget(const KAboutData &abtData, int layoutType, TQWidget *parent = 0, char *name = 0);
virtual void show( void ); virtual void show( void );
virtual TQSize tqsizeHint( void ) const; virtual TQSize tqsizeHint( void ) const;

@ -34,7 +34,7 @@ Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
FrequencySeekHelper(ISeekRadio &tqparent); FrequencySeekHelper(ISeekRadio &parent);
virtual ~FrequencySeekHelper(); virtual ~FrequencySeekHelper();
// IFrequencyRadioClient // IFrequencyRadioClient

@ -35,7 +35,7 @@ public:
PluginConfigurationDialog( PluginConfigurationDialog(
int dialogFace, const TQString &caption, int dialogFace, const TQString &caption,
int buttonMask, ButtonCode defaultButton, int buttonMask, ButtonCode defaultButton,
TQWidget *tqparent=0, const char *name=0, TQWidget *parent=0, const char *name=0,
bool modal=true, bool separator=false); bool modal=true, bool separator=false);
// PluginBase // PluginBase

@ -33,7 +33,7 @@ class PluginManagerConfiguration : public PluginManagerConfigurationUI
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
PluginManagerConfiguration (TQWidget *tqparent, KRadioApp *app, PluginManager *pm); PluginManagerConfiguration (TQWidget *parent, KRadioApp *app, PluginManager *pm);
~PluginManagerConfiguration (); ~PluginManagerConfiguration ();
void noticePluginLibrariesChanged(); void noticePluginLibrariesChanged();

@ -31,7 +31,7 @@ class RadioStationConfig : public TQWidget
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
RadioStationConfig(TQWidget *tqparent); RadioStationConfig(TQWidget *parent);
~RadioStationConfig(); ~RadioStationConfig();
virtual void setStationData (const RadioStation &rs) = 0; virtual void setStationData (const RadioStation &rs) = 0;
@ -47,7 +47,7 @@ class UndefinedRadioStationConfig : public RadioStationConfig
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
UndefinedRadioStationConfig (TQWidget *tqparent); UndefinedRadioStationConfig (TQWidget *parent);
~UndefinedRadioStationConfig(); ~UndefinedRadioStationConfig();
virtual void setStationData (const RadioStation &rs); virtual void setStationData (const RadioStation &rs);
@ -63,7 +63,7 @@ class FrequencyRadioStationConfig : public RadioStationConfig
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
FrequencyRadioStationConfig (TQWidget *tqparent); FrequencyRadioStationConfig (TQWidget *parent);
~FrequencyRadioStationConfig(); ~FrequencyRadioStationConfig();
virtual void setStationData (const RadioStation &rs); virtual void setStationData (const RadioStation &rs);

@ -33,7 +33,7 @@ class RadioStationListView : public KListView
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
RadioStationListView(TQWidget *tqparent=0, const char *name=0); RadioStationListView(TQWidget *parent=0, const char *name=0);
virtual ~RadioStationListView(); virtual ~RadioStationListView();
TQListViewItem *getItemForIndex(int idx) const; TQListViewItem *getItemForIndex(int idx) const;

@ -33,7 +33,7 @@ public:
typedef enum { off, searchWorse, searchBest } state_t; typedef enum { off, searchWorse, searchBest } state_t;
typedef enum { up, down } direction_t; typedef enum { up, down } direction_t;
SeekHelper(ISeekRadio &tqparent); SeekHelper(ISeekRadio &parent);
virtual ~SeekHelper(); virtual ~SeekHelper();
virtual bool connectI (Interface *i); virtual bool connectI (Interface *i);

@ -38,7 +38,7 @@ class StandardScanDialog : public StandardScanDialogUI,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public: public:
StandardScanDialog(TQWidget *tqparent); StandardScanDialog(TQWidget *parent);
~StandardScanDialog(); ~StandardScanDialog();
bool connectI (Interface *i); bool connectI (Interface *i);

@ -41,7 +41,7 @@ class StationSelector : public StationSelectorUI,
Q_OBJECT Q_OBJECT
TQ_OBJECT TQ_OBJECT
public : public :
StationSelector (TQWidget *tqparent); StationSelector (TQWidget *parent);
~StationSelector (); ~StationSelector ();
bool connectI (Interface *i); bool connectI (Interface *i);

@ -22,10 +22,10 @@
PluginConfigurationDialog::PluginConfigurationDialog( PluginConfigurationDialog::PluginConfigurationDialog(
int dialogFace, const TQString &caption, int dialogFace, const TQString &caption,
int buttonMask, ButtonCode defaultButton, int buttonMask, ButtonCode defaultButton,
TQWidget *tqparent, const char *name, TQWidget *parent, const char *name,
bool modal, bool separator) bool modal, bool separator)
: KDialogBase(dialogFace, caption, buttonMask, defaultButton, : KDialogBase(dialogFace, caption, buttonMask, defaultButton,
tqparent, name, modal, separator), parent, name, modal, separator),
WidgetPluginBase (name, i18n("Configuration Dialog")), WidgetPluginBase (name, i18n("Configuration Dialog")),
m_Caption(caption) m_Caption(caption)
{ {

@ -28,8 +28,8 @@
#include <tqcheckbox.h> #include <tqcheckbox.h>
PluginManagerConfiguration::PluginManagerConfiguration(TQWidget *tqparent, KRadioApp *app, PluginManager *pm) PluginManagerConfiguration::PluginManagerConfiguration(TQWidget *parent, KRadioApp *app, PluginManager *pm)
: PluginManagerConfigurationUI(tqparent), : PluginManagerConfigurationUI(parent),
m_Application(app), m_Application(app),
m_PluginManager(pm), m_PluginManager(pm),
m_dirty(true) m_dirty(true)

@ -322,7 +322,7 @@ void PluginManager::createConfigDialog(const TQString &title)
title, title,
KDialogBase::Apply|KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Apply|KDialogBase::Ok|KDialogBase::Cancel,
KDialogBase::Ok, KDialogBase::Ok,
/*tqparent = */ NULL, /*parent = */ NULL,
title.ascii(), title.ascii(),
/*modal = */ false, /*modal = */ false,
true); true);
@ -398,7 +398,7 @@ void PluginManager::createAboutDialog(const TQString &title)
title, title,
KDialogBase::Close, KDialogBase::Close,
KDialogBase::Close, KDialogBase::Close,
/*tqparent = */ NULL, /*parent = */ NULL,
title.ascii(), title.ascii(),
/*modal = */ false, /*modal = */ false,
true); true);

@ -26,8 +26,8 @@
#include "include/frequencyradiostation.h" #include "include/frequencyradiostation.h"
RadioStationConfig::RadioStationConfig(TQWidget *tqparent) RadioStationConfig::RadioStationConfig(TQWidget *parent)
: TQWidget (tqparent) : TQWidget (parent)
{ {
} }
@ -39,8 +39,8 @@ RadioStationConfig::~RadioStationConfig()
/////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////
UndefinedRadioStationConfig::UndefinedRadioStationConfig (TQWidget *tqparent) UndefinedRadioStationConfig::UndefinedRadioStationConfig (TQWidget *parent)
: RadioStationConfig(tqparent) : RadioStationConfig(parent)
{ {
new TQLabel (i18n("I don't know how to edit this station"), this); new TQLabel (i18n("I don't know how to edit this station"), this);
} }
@ -60,8 +60,8 @@ void UndefinedRadioStationConfig::storeStationData (RadioStation &/*rs*/)
/////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////
FrequencyRadioStationConfig::FrequencyRadioStationConfig (TQWidget *tqparent) FrequencyRadioStationConfig::FrequencyRadioStationConfig (TQWidget *parent)
: RadioStationConfig(tqparent) : RadioStationConfig(parent)
{ {
TQHBoxLayout *hl = new TQHBoxLayout(this); TQHBoxLayout *hl = new TQHBoxLayout(this);
TQVBoxLayout *vl = new TQVBoxLayout(hl); TQVBoxLayout *vl = new TQVBoxLayout(hl);

@ -27,8 +27,8 @@
#include <kconfig.h> #include <kconfig.h>
RadioStationListView::RadioStationListView(TQWidget *tqparent, const char *name) RadioStationListView::RadioStationListView(TQWidget *parent, const char *name)
: KListView(tqparent, name) : KListView(parent, name)
{ {
addColumn(i18n("No.")); addColumn(i18n("No."));
addColumn(i18n("Icon")); addColumn(i18n("Icon"));

@ -19,9 +19,9 @@
#include <kdebug.h> #include <kdebug.h>
SeekHelper::SeekHelper(ISeekRadio &tqparent) SeekHelper::SeekHelper(ISeekRadio &parent)
: m_state(off), : m_state(off),
m_parent(tqparent), m_parent(parent),
m_SoundStreamID(SoundStreamID::InvalidID) m_SoundStreamID(SoundStreamID::InvalidID)
{ {
} }

@ -87,15 +87,15 @@ int SoundFormat::convertSampleToInt(const char *sample, bool do_scale) const
} }
int scale = (sizeof(unsigned) << 3) - m_SampleBits; int scale = (sizeof(unsigned) << 3) - m_SampleBits;
int signtqmask = do_scale ? (!m_IsSigned << ((sizeof(unsigned) << 3) - 1)) : int signmask = do_scale ? (!m_IsSigned << ((sizeof(unsigned) << 3) - 1)) :
(-m_IsSigned << ((size << 3) - 1)) ; (-m_IsSigned << ((size << 3) - 1)) ;
if (do_scale) { if (do_scale) {
// map to int number space // map to int number space
return (val << scale) ^ signtqmask; return (val << scale) ^ signmask;
} else { } else {
// do only sign extension // do only sign extension
if (val & signtqmask) if (val & signmask)
val |= signtqmask; val |= signmask;
return val; return val;
} }
} }
@ -105,9 +105,9 @@ void SoundFormat::convertIntToSample(int src, char *dst, bool is_scaled) const
{ {
int size = sampleSize(); int size = sampleSize();
int scale = (sizeof(unsigned) * 8) - m_SampleBits; int scale = (sizeof(unsigned) * 8) - m_SampleBits;
int signtqmask = (!m_IsSigned << (sizeof(unsigned) * 8 - 1)); int signmask = (!m_IsSigned << (sizeof(unsigned) * 8 - 1));
unsigned val = is_scaled ? (src ^ signtqmask) >> scale : src; unsigned val = is_scaled ? (src ^ signmask) >> scale : src;
if (m_Endianess == LITTLE_ENDIAN) { if (m_Endianess == LITTLE_ENDIAN) {
for (int i = 0; i < size; ++i, ++dst) { for (int i = 0; i < size; ++i, ++dst) {
(unsigned char &)*dst = val & 0xFF; (unsigned char &)*dst = val & 0xFF;
@ -127,7 +127,7 @@ void SoundFormat::convertSamplesToInts(const char *src, int *dst, size_t n, bool
{ {
int size = sampleSize(); int size = sampleSize();
int scale = (sizeof(unsigned) * 8) - m_SampleBits; int scale = (sizeof(unsigned) * 8) - m_SampleBits;
int signtqmask = do_scale ? (!m_IsSigned << ((sizeof(unsigned) << 3) - 1)) : int signmask = do_scale ? (!m_IsSigned << ((sizeof(unsigned) << 3) - 1)) :
(-m_IsSigned << ((size << 3) - 1)) ; (-m_IsSigned << ((size << 3) - 1)) ;
if (m_Endianess == LITTLE_ENDIAN) { if (m_Endianess == LITTLE_ENDIAN) {
src = src - 1 + (size * n); src = src - 1 + (size * n);
@ -138,9 +138,9 @@ void SoundFormat::convertSamplesToInts(const char *src, int *dst, size_t n, bool
val = (val << 8) | (unsigned char)*src; val = (val << 8) | (unsigned char)*src;
} }
if (do_scale) { if (do_scale) {
*dst = (val << scale) ^ signtqmask; *dst = (val << scale) ^ signmask;
} else if (val & signtqmask) { } else if (val & signmask) {
*dst = val | signtqmask; *dst = val | signmask;
} }
} }
} else { } else {
@ -150,9 +150,9 @@ void SoundFormat::convertSamplesToInts(const char *src, int *dst, size_t n, bool
val = (val << 8) | (unsigned char)*src; val = (val << 8) | (unsigned char)*src;
} }
if (do_scale) { if (do_scale) {
*dst = (val << scale) ^ signtqmask; *dst = (val << scale) ^ signmask;
} else if (val & signtqmask) { } else if (val & signmask) {
*dst = val | signtqmask; *dst = val | signmask;
} }
} }
} }
@ -163,11 +163,11 @@ void SoundFormat::convertIntsToSamples(const int *src, char *dst, size_t n, bool
{ {
int size = sampleSize(); int size = sampleSize();
int scale = (sizeof(unsigned) * 8) - m_SampleBits; int scale = (sizeof(unsigned) * 8) - m_SampleBits;
int signtqmask = (!m_IsSigned << (sizeof(unsigned) * 8 - 1)); int signmask = (!m_IsSigned << (sizeof(unsigned) * 8 - 1));
if (m_Endianess == LITTLE_ENDIAN) { if (m_Endianess == LITTLE_ENDIAN) {
for (const int *end = src+n; src < end; ++src) { for (const int *end = src+n; src < end; ++src) {
unsigned val = is_scaled ? ((unsigned)(*src ^ signtqmask)) >> scale : *src; unsigned val = is_scaled ? ((unsigned)(*src ^ signmask)) >> scale : *src;
for (int i = 0; i < size; ++i, ++dst) { for (int i = 0; i < size; ++i, ++dst) {
(unsigned char &)*dst = val & 0xFF; (unsigned char &)*dst = val & 0xFF;
val >>= 8; val >>= 8;
@ -177,7 +177,7 @@ void SoundFormat::convertIntsToSamples(const int *src, char *dst, size_t n, bool
dst = dst - 1 + (size * n); dst = dst - 1 + (size * n);
const int *end = src; const int *end = src;
for (src = src - 1 + n; src >= end; --src) { for (src = src - 1 + n; src >= end; --src) {
unsigned val = is_scaled ? ((unsigned)(*src ^ signtqmask)) >> scale : *src; unsigned val = is_scaled ? ((unsigned)(*src ^ signmask)) >> scale : *src;
for (int i = size - 1; i >= 0; --i, --dst) { for (int i = size - 1; i >= 0; --i, --dst) {
(unsigned char &)*dst = val & 0xFF; (unsigned char &)*dst = val & 0xFF;
val >>= 8; val >>= 8;
@ -192,7 +192,7 @@ void SoundFormat::convertSamplesToFloat(const char *_src, float **_dst, size_t n
int sample_size = sampleSize(); int sample_size = sampleSize();
int frame_size = frameSize(); int frame_size = frameSize();
int scale = (sizeof(short) << 3) - m_SampleBits; int scale = (sizeof(short) << 3) - m_SampleBits;
int signtqmask = !m_IsSigned << ((sizeof(short) << 3) - 1); int signmask = !m_IsSigned << ((sizeof(short) << 3) - 1);
int skip = frame_size - sample_size; int skip = frame_size - sample_size;
if (m_Endianess == LITTLE_ENDIAN) { if (m_Endianess == LITTLE_ENDIAN) {
@ -206,7 +206,7 @@ void SoundFormat::convertSamplesToFloat(const char *_src, float **_dst, size_t n
for (int i = sample_size - 1; i >= 0; --i, --src) { for (int i = sample_size - 1; i >= 0; --i, --src) {
val = (val << 8) | (unsigned char)*src; val = (val << 8) | (unsigned char)*src;
} }
*dst = (float)(signed short)((val << scale) ^ signtqmask) / 32768.0f; *dst = (float)(signed short)((val << scale) ^ signmask) / 32768.0f;
src = src - skip; src = src - skip;
} }
} }
@ -219,7 +219,7 @@ void SoundFormat::convertSamplesToFloat(const char *_src, float **_dst, size_t n
for (int i = 0; i < sample_size; ++i, ++src) { for (int i = 0; i < sample_size; ++i, ++src) {
val = (val << 8) | (unsigned char)*src; val = (val << 8) | (unsigned char)*src;
} }
*dst = (float)(signed short)((val << scale) ^ signtqmask) / 32768.0f; *dst = (float)(signed short)((val << scale) ^ signmask) / 32768.0f;
src = src + skip; src = src + skip;
} }
} }
@ -233,7 +233,7 @@ void SoundFormat::convertFloatsToSamples(const float **_src, char *_dst, size_t
int sample_size = sampleSize(); int sample_size = sampleSize();
int frame_size = frameSize(); int frame_size = frameSize();
int scale = (sizeof(short) << 3) - m_SampleBits; int scale = (sizeof(short) << 3) - m_SampleBits;
int signtqmask = (!m_IsSigned << (sizeof(short) << 3) - 1); int signmask = (!m_IsSigned << (sizeof(short) << 3) - 1);
int skip = frame_size - sample_size; int skip = frame_size - sample_size;
if (m_Endianess == LITTLE_ENDIAN) { if (m_Endianess == LITTLE_ENDIAN) {
@ -241,7 +241,7 @@ void SoundFormat::convertFloatsToSamples(const float **_src, char *_dst, size_t
const float *src = _src[ch]; const float *src = _src[ch];
char *dst = _dst + ch * sample_size; char *dst = _dst + ch * sample_size;
for (const float *end = src+n; src < end; ++src) { for (const float *end = src+n; src < end; ++src) {
unsigned val = (( ((unsigned)(*src * 32768.0f)) ^ signtqmask)) >> scale; unsigned val = (( ((unsigned)(*src * 32768.0f)) ^ signmask)) >> scale;
for (int i = 0; i < sample_size; ++i, ++dst) { for (int i = 0; i < sample_size; ++i, ++dst) {
(unsigned char &)*dst = val & 0xFF; (unsigned char &)*dst = val & 0xFF;
val >>= 8; val >>= 8;
@ -256,7 +256,7 @@ void SoundFormat::convertFloatsToSamples(const float **_src, char *_dst, size_t
const float *src = _src[ch]; const float *src = _src[ch];
const float *end = src; const float *end = src;
for (src = src - 1 + n; src >= end; --src) { for (src = src - 1 + n; src >= end; --src) {
unsigned val = (( ((unsigned)(*src * 32768.0f)) ^ signtqmask)) >> scale; unsigned val = (( ((unsigned)(*src * 32768.0f)) ^ signmask)) >> scale;
for (int i = sample_size - 1; i >= 0; --i, --dst) { for (int i = sample_size - 1; i >= 0; --i, --dst) {
(unsigned char &)*dst = val & 0xFF; (unsigned char &)*dst = val & 0xFF;
val >>= 8; val >>= 8;

@ -26,8 +26,8 @@
#include <math.h> #include <math.h>
StandardScanDialog::StandardScanDialog(TQWidget *tqparent) StandardScanDialog::StandardScanDialog(TQWidget *parent)
: StandardScanDialogUI(tqparent, NULL, true), : StandardScanDialogUI(parent, NULL, true),
m_count(0), m_count(0),
m_running(false), m_running(false),
m_oldPowerOn(false), m_oldPowerOn(false),

@ -26,8 +26,8 @@ using namespace std;
#include "include/stationselector.h" #include "include/stationselector.h"
#include "include/radiostation-listview.h" #include "include/radiostation-listview.h"
StationSelector::StationSelector (TQWidget *tqparent) StationSelector::StationSelector (TQWidget *parent)
: StationSelectorUI(tqparent), : StationSelectorUI(parent),
m_dirty(true) m_dirty(true)
{ {
TQObject::connect(buttonToLeft, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotButtonToLeft())); TQObject::connect(buttonToLeft, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotButtonToLeft()));

Loading…
Cancel
Save