Commit 1a3d591b authored by tfarina's avatar tfarina Committed by Commit bot

base: Fix warnings found by clang chromium-style plugin on Windows.

http://build.chromium.org/p/chromium.fyi/builders/CrWinClang/builds/596/steps/compile/logs/stdio

..\..\base/win/shortcut.h(51,3) :  warning(clang): [chromium-style] Complex constructor has an inlined body.
ShortcutProperties() : icon_index(-1), dual_mode(false), options(0U) {}
                      ^
..\..\base/win/shortcut.h(32,1) :  warning(clang): [chromium-style] Complex class/struct needs an explicit out-of-line destructor.
struct ShortcutProperties {
    ^
2 warnings generated.

BUG=467287
R=thakis@chromium.org

Review URL: https://codereview.chromium.org/1100403003

Cr-Commit-Position: refs/heads/master@{#326995}
parent 49df824b
......@@ -42,6 +42,13 @@ void InitializeShortcutInterfaces(
} // namespace
ShortcutProperties::ShortcutProperties()
: icon_index(-1), dual_mode(false), options(0U) {
}
ShortcutProperties::~ShortcutProperties() {
}
bool CreateOrUpdateShortcutLink(const FilePath& shortcut_path,
const ShortcutProperties& properties,
ShortcutOperation operation) {
......
......@@ -7,6 +7,7 @@
#include <windows.h>
#include "base/base_export.h"
#include "base/files/file_path.h"
#include "base/logging.h"
#include "base/strings/string16.h"
......@@ -29,7 +30,7 @@ enum ShortcutOperation {
// creation/update, others will be ignored.
// Callers are encouraged to use the setters provided which take care of
// setting |options| as desired.
struct ShortcutProperties {
struct BASE_EXPORT ShortcutProperties {
enum IndividualProperties {
PROPERTIES_TARGET = 1U << 0,
PROPERTIES_WORKING_DIR = 1U << 1,
......@@ -48,7 +49,8 @@ struct ShortcutProperties {
PROPERTIES_ALL = PROPERTIES_BASIC | PROPERTIES_WIN7
};
ShortcutProperties() : icon_index(-1), dual_mode(false), options(0U) {}
ShortcutProperties();
~ShortcutProperties();
void set_target(const FilePath& target_in) {
target = target_in;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment