From db43a54963b62a2a3874c5d0b89668dec19356fa Mon Sep 17 00:00:00 2001 From: Gustavo Jose de Sousa Date: Tue, 11 Aug 2015 16:28:45 +1000 Subject: [PATCH] AP_Parachute: standardize inclusion of libaries headers This commit changes the way libraries headers are included in source files: - If the header is in the same directory the source belongs to, so the notation '#include ""' is used with the path relative to the directory containing the source. - If the header is outside the directory containing the source, then we use the notation '#include <>' with the path relative to libraries folder. Some of the advantages of such approach: - Only one search path for libraries headers. - OSs like Windows may have a better lookup time. --- libraries/AP_Parachute/AP_Parachute.cpp | 12 +++++----- libraries/AP_Parachute/AP_Parachute.h | 6 ++--- .../AP_Parachute_test/AP_Parachute_test.cpp | 22 +++++++++---------- 3 files changed, 20 insertions(+), 20 deletions(-) diff --git a/libraries/AP_Parachute/AP_Parachute.cpp b/libraries/AP_Parachute/AP_Parachute.cpp index d0bcb472f0..70f9e313af 100644 --- a/libraries/AP_Parachute/AP_Parachute.cpp +++ b/libraries/AP_Parachute/AP_Parachute.cpp @@ -1,11 +1,11 @@ // -*- tab-width: 4; Mode: C++; c-basic-offset: 4; indent-tabs-mode: nil -*- -#include -#include -#include -#include -#include -#include +#include "AP_Parachute.h" +#include +#include +#include +#include +#include extern const AP_HAL::HAL& hal; diff --git a/libraries/AP_Parachute/AP_Parachute.h b/libraries/AP_Parachute/AP_Parachute.h index 1ce242f2d5..e5dcbedfc8 100644 --- a/libraries/AP_Parachute/AP_Parachute.h +++ b/libraries/AP_Parachute/AP_Parachute.h @@ -6,9 +6,9 @@ #ifndef AP_PARACHUTE_H #define AP_PARACHUTE_H -#include -#include -#include +#include +#include +#include #define AP_PARACHUTE_TRIGGER_TYPE_RELAY_0 0 #define AP_PARACHUTE_TRIGGER_TYPE_RELAY_1 1 diff --git a/libraries/AP_Parachute/examples/AP_Parachute_test/AP_Parachute_test.cpp b/libraries/AP_Parachute/examples/AP_Parachute_test/AP_Parachute_test.cpp index e80e01900c..6ea39dd550 100644 --- a/libraries/AP_Parachute/examples/AP_Parachute_test/AP_Parachute_test.cpp +++ b/libraries/AP_Parachute/examples/AP_Parachute_test/AP_Parachute_test.cpp @@ -3,17 +3,17 @@ * DIYDrones.com */ -#include -#include -#include // ArduPilot Mega Vector/Matrix math Library -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include // ArduPilot Mega Vector/Matrix math Library +#include +#include +#include +#include +#include +#include +#include +#include const AP_HAL::HAL& hal = AP_HAL_BOARD_DRIVER;