]> sigrok.org Git - pulseview.git/commitdiff
Fixes for clang build on OS X
authorRene Hopf <redacted>
Wed, 23 Oct 2013 06:59:44 +0000 (07:59 +0100)
committerJoel Holdsworth <redacted>
Wed, 23 Oct 2013 06:59:44 +0000 (07:59 +0100)
pv/dialogs/decoder.cpp
pv/dialogs/decoder.h
pv/view/ruler.cpp

index b7ddb52135a52824c0f335a67b6c47d0e8f708d6..88ccf76021f9acc7b7888695257cacc6f673c684 100644 (file)
@@ -42,9 +42,7 @@ namespace dialogs {
 Decoder::Decoder(QWidget *parent, const srd_decoder *decoder,
        const vector< shared_ptr<view::Signal> > &sigs, GHashTable *options) :
        QDialog(parent),
-       _decoder(decoder),
        _sigs(sigs),
-       _options(options),
        _binding(decoder, options),
        _layout(this),
        _form(this),
index 2277f987c23e4b0250ec715b1882949d4f4a43fd..56f02aa4480bf627d52d66883ed6cfc2ae8940ec 100644 (file)
@@ -62,12 +62,10 @@ private:
                QWidget *parent, const char *name);
 
 private:
-       const srd_decoder *const _decoder;
        const std::vector< boost::shared_ptr<view::Signal> > &_sigs;
 
        std::map<const srd_probe*, QComboBox*> _probe_selector_map;
 
-       GHashTable *const _options;
        pv::prop::binding::DecoderOptions _binding;
 
        QVBoxLayout _layout;
index a9a8452d47fc6784d6d736762ba4938ce3408895..bf1507a7fab31d0117e67ec4d18e50db8a0bbab0 100644 (file)
@@ -74,7 +74,7 @@ QString Ruler::format_time(double t, unsigned int prefix,
        unsigned int precision)
 {
        const double multiplier = pow(10.0,
-               - prefix * 3 - FirstSIPrefixPower);
+               (int)- prefix * 3 - FirstSIPrefixPower);
 
        QString s;
        QTextStream ts(&s);
@@ -106,7 +106,7 @@ void Ruler::paintEvent(QPaintEvent*)
                const double min_period = _view.scale() * min_width;
 
                const int order = (int)floorf(log10f(min_period));
-               const double order_decimal = pow(10, order);
+               const double order_decimal = pow(10.0, order);
 
                unsigned int unit = 0;