Commit Graph

79 Commits

Author SHA1 Message Date
Klaus Basan
f049900e1f Ref T223, use const values for standard pressure
* standardISASeaLevelPressure
* use static const values for standard pressure
* minor formatting
2018-01-15 23:00:34 +01:00
Klaus Basan
b2c0d726bc Ref T215, PQ integer support 2018-01-13 05:04:33 +01:00
Klaus Basan
efd4e110b7 Ref T172, formatting
* this->m_ => m_
* formatting
* comments / doxygen
2017-12-28 18:44:32 +01:00
Mathew Sutcliffe
3ae5e274ee Removed workarounds that were needed to support older versions of MSVC. 2017-11-14 17:51:02 +00:00
Roland Winklmeier
c91aa0d58e Change template parameter to disambiguate call to QLatin1String constructor
Summary:
Qt 5.10 added a new constructor overload which made the call to QLatin1String
constructor with size_t as second parameter ambigious.

Reviewers: #swift_pilot_client, msutcliffe

Reviewed By: #swift_pilot_client, msutcliffe

Subscribers: jenkins

Differential Revision: https://dev.swift-project.org/D47
2017-09-24 19:52:41 +01:00
Klaus Basan
3f924209f1 As a follow up of review T111, changed "void static" to "static void" for consistency. 2017-09-24 19:52:31 +01:00
Klaus Basan
58b5dd1278 Using std::copysign 2017-09-24 19:52:05 +01:00
Klaus Basan
9445bd56a3 Ref T111, normalize utility functions 2017-09-24 19:51:33 +01:00
Klaus Basan
4e45496431 Ref T111, different implementation as recommended by MS 2017-09-24 19:51:31 +01:00
Klaus Basan
f936f07c8d Ref T120, PQ units: made final and removed virtual dtor 2017-09-24 19:51:25 +01:00
Klaus Basan
e55480737e Ref T111, lat/lng/angle changes
* get struct CAngle::DegMinSecFractionalSec to obtain parts
* round to epsilon utility functions and fix (qint64)
2017-09-24 19:51:09 +01:00
Mathew Sutcliffe
fd649c0b5c T73 Added virtual final destructors in CMeasurementUnit derived classes.
This fixes the GCC warning "deleting polymorphic object with non-virtual destructor".
They are marked final so the virtual dispatch can be optimized out, because they don't need to be overridden.
2017-05-14 17:21:31 +01:00
Mathew Sutcliffe
07ec7e6bc1 T73 Pass units by value.
Class types which are trivial to copy should be passed by value.
2017-05-14 17:21:30 +01:00
Mathew Sutcliffe
c8d78ada65 T73 Flyweight pattern based on pimpl, to reduce CMeasurementUnit memory usage.
* All members of CMeasurementUnit moved into nested pimpl class Data.
* CMeasurementUnit has only one member: a pointer to a const Data.
* Static const CMeasurementUnits replaced with static const Datas.
* Each CMeasurementUnit singleton method returns by-value a CMeasurementUnit containing a pointer to a static const Data.
* Means CMeasurementUnit is trivial to copy because we never copy the pimpl members.
** Works because the available units are fixed at compile time so we never need to create novel units at runtime.
2017-05-14 17:21:23 +01:00
Mathew Sutcliffe
fef2bc528e T73 Enabled for constexpr, to take advantage of constant-initialization.
* CMeasurementUnit and every one of its members is a literal type.
** This requires using QLatin1String instead of QString.
* Every static const CMeasurementUnit is static constexpr.
** This means they are initialized at compile time, no runtime initialization needed.
2017-05-14 17:13:40 +01:00
Mathew Sutcliffe
5e4349bba6 T73 Style. 2017-05-14 15:08:04 +01:00
Mathew Sutcliffe
48482d8d1e T73 CMeasurementUnit converter strategy based on function pointers.
Because function pointers are literal types, so they can be constexpr.
2017-05-14 15:08:03 +01:00
Mathew Sutcliffe
895190c4d0 T73 Fixed non-threadsafe static initialization. 2017-05-14 15:08:01 +01:00
Mathew Sutcliffe
d5ab73e1bc Replace QRegExp with QRegularExpression
Reviewers: kbasan, msutcliffe

Reviewed By: kbasan, msutcliffe

Subscribers: jenkins

Differential Revision: https://dev.swift-project.org/D11
2017-05-05 23:08:35 +01:00
Mathew Sutcliffe
a8302b310e refs #937 Resolved clazy warnings: QString::arg. 2017-04-19 19:31:45 +01:00
Mathew Sutcliffe
3ea9e33e6b refs #937 Resolved clazy warnings: pass-by-value/reference. 2017-04-19 19:31:42 +01:00
Mathew Sutcliffe
b7f69c6887 refs #937 Resolved clazy warnings: unnecessary memory allocation. 2017-04-19 19:31:39 +01:00
Klaus Basan
b77c04c99c refs #875, fixed PQ null for DBus 2017-02-24 15:21:01 +00:00
Klaus Basan
e49f9c2b38 Fixed output of PQ null values 2017-02-24 00:19:02 +00:00
Mathew Sutcliffe
1c7fb518ca Fixed broken link URLs in comments. 2017-02-24 00:18:16 +00:00
Klaus Basan
9eff387207 Removed deprecated funtions and changed code to use new functions 2017-01-10 23:47:10 +00:00
Mathew Sutcliffe
bbdbd26f82 refs #815 Throw CJsonException when required JSON objects are not found. 2017-01-10 23:46:33 +00:00
Mathew Sutcliffe
0ca9fe0a8a refs #837 Abbreviated syntax for specifying a null unit. 2017-01-10 23:44:28 +00:00
Mathew Sutcliffe
3ab121a593 refs #802 Fixed linker errors for exported explicit template instantiations with Clang on Windows. 2016-12-13 19:00:44 +01:00
Klaus Basan
438e72555a refs #799, own component for view update times
* utility function in CTime
* settings class for update times
2016-12-13 18:59:48 +01:00
Klaus Basan
8a5d50a167 refs #780, fixed property index compare issues found in the client 2016-12-06 09:46:57 +01:00
Klaus Basan
3ca9d729c8 refs #685, utility function 2016-06-29 01:04:23 +02:00
Roland Winklmeier
3d7a39ed00 Fix BlackMisc header includes
* Include only what is used
* Use forward declaration when possible
* Sorted includes

refs #630
2016-05-13 17:05:49 +02:00
Klaus Basan
0f5d2a29a8 refs #655, Change signature (order) of setProperty/compareProperty 2016-05-13 16:44:17 +02:00
Mathew Sutcliffe
4e9d7d3efe refs #628 Metaclass style compatible with the AStyle beautifier. 2016-04-06 15:15:12 +01:00
Mathew Sutcliffe
0acb302c63 refs #628 Remove the old tuple system. 2016-04-03 18:17:44 +01:00
Mathew Sutcliffe
4bd4baa535 refs #628 Use the metaclass mixins in all value classes. 2016-04-03 18:17:43 +01:00
Mathew Sutcliffe
6f1cf8e3d7 refs #624 Replace typedef with using. 2016-03-22 16:02:50 +00:00
Klaus Basan
c3722f9198 refs #485, refs #584 removed include blackmiscfreefunctions.h 2016-03-18 01:07:49 +00:00
Roland Winklmeier
39285541b7 Fix CTime unit test failure with MinGW build 2016-03-02 23:04:46 +01:00
Roland Winklmeier
7953d550ea Fix linux clang errors and warnings
refs #596
2016-02-15 18:35:34 +01:00
Mathew Sutcliffe
3bdcd7e386 refs #584 Moved hash related stuff to dictionary.h
This also means moving Mixin::Icon from CContainerBase one step down the inheritance hierarchy
to resolve what would otherwise have been a circular include dependency.
2016-02-08 17:26:45 +00:00
Roland Winklmeier
794bf0cd74 Fix doxygen copydoc documentation
The following issues were fixed
* Fixed wrong/missing namespaces
* Fixed obvious typos in documentation
* Documentation not in sync with source code

refs #544
2016-02-08 01:53:17 +01:00
Mathew Sutcliffe
e6011ec7cd refs #552 Style & doxygen. 2015-12-13 16:38:13 +00:00
Mathew Sutcliffe
c1d57b8971 refs #552 Fixed broken SubdivisionConverter, and added another test to verify. 2015-12-13 16:38:10 +00:00
Mathew Sutcliffe
1f36f07bed refs #552 Fixed broken SubdivisionConverter2, and added a test to verify. 2015-12-13 16:38:07 +00:00
Klaus Basan
1fc7300982 refs #507, split up blackmiscfreefunctions
* single register metadata functions
* string utils
* metadata utils
* some formatting / license header where applicable
2015-11-22 02:42:29 +01:00
Mathew Sutcliffe
7483195b47 refs #484 Trigonometry methods in CAngle. 2015-11-19 21:04:54 +00:00
Klaus Basan
0c94922bd6 refs #501, compareByPropertyIndex (performance for sort) 2015-11-19 21:04:34 +00:00
Mathew Sutcliffe
b1a3793c2f refs #466 Resolved miscellaneous TODO items. 2015-11-19 21:01:02 +00:00