Commit graph

22 commits

Author SHA1 Message Date
Charles Kerr
d663b4eaee
fix: fix gn cpplint warnings (#14583)
* chore: fix cpplint 'include_what_you_use' warnings

Typically by including <memory>, <utility> etc.

* chore: fix 'static/global string constant' warning

Use C style strings instead of std::string.

Style guide forbids non-trivial static / global variables. https://google.github.io/styleguide/cppguide.html#Static_and_Global_Variables

/home/charles/electron/electron-gn/src/electron/script/cpplint.js

* refactor: remove global string variables.

Fix 'global string variables are not permitted' linter warnings
by using the base::NoDestructor<> wrapper to make it explicit that
these variables are never destroyed.

The style guide's take on globals with nontrivial destructors:
https://google.github.io/styleguide/cppguide.html#Static_and_Global_Variables

* fix: initializer error introduced in last commit

* fix: remove WIP file that was included by accident

* fix: include order

* fix: include order

* fix: include order

* fix: include order, again
2018-09-12 19:25:56 -05:00
Milan Burda
932f6c8a41 feat: add screen reader support to Win32 toast notifications (#13834) 2018-09-13 00:18:35 +10:00
Jeremy Apthorp
3a58545a59 chore: replace _ASSERT with DCHECK in toast.cc (#13598)
_ASSERT was triggering errors about unused values when in debug mode
2018-07-10 08:01:26 -07:00
Jeremy Apthorp
6492732631
chore: [gn] fix link errors relating to static members (#13488)
I'm not 100% sure why this is working in the gyp build, but I was getting link errors with these variables being defined in the headers.
2018-06-28 14:25:26 -07:00
Jeremy Apthorp
418c4e170c
chore: [gn] only define WIN32_LEAN_AND_MEAN if not already defined (#13430)
Chromium's GN build already defines `WIN32_LEAN_AND_MEAN` and `NOMINMAX` (see [build/config/win/BUILD.gn](dbe762aaff/build/config/win/BUILD.gn (515)) in chrome), so we don't need to define them ourselves. Left as #ifndefs so as not to break the gyp build.
2018-06-26 02:00:50 +02:00
Jeremy Apthorp
43c1a7778d chore: fix chromium-style errors in windows code 2018-06-21 16:50:58 -07:00
Shelley Vohr
49c8c31220
format previously misses .cc files 2018-04-17 21:56:12 -04:00
Ales Pergl
75feb495ad Fix for narrowing conversion warnings, minor style change 2017-09-25 18:08:54 +02:00
Yuya Ochiai
d621471eb2 🏁 Set duration for Windows 7 notifications based on Control Panel 2017-09-22 21:28:29 +09:00
Kevin Sawicki
d7321ed980 Add brightray prefix to include paths from within brightray 2017-05-19 08:46:15 -07:00
Ales Pergl
f73233ee55 Changed local variable and parameter names to snake case style 2017-04-05 14:30:17 +02:00
Ales Pergl
9d75e9f54c Address cpplint issue "Namespace should be terminated with "// namespace brightray" [readability/namespace] [5]" 2017-04-05 14:30:16 +02:00
Ales Pergl
64bf0d210e Address cpplint issue "An else should appear on the same line as the preceding } [whitespace/newline] [4]" 2017-04-05 14:30:16 +02:00
Ales Pergl
9b7fbd4d22 Address cpplint issue "Using C-style cast. Use reinterpret_cast<BYTE*>(...) instead [readability/casting] [4]" 2017-04-05 14:30:16 +02:00
Ales Pergl
91cff2e6c7 Address cpplint issue "Missing space before ( in if( [whitespace/parens] [5]" 2017-04-05 14:30:16 +02:00
Ales Pergl
29f3332276 Address cpplint issue "{ should almost always be at the end of the previous line [whitespace/braces] [4]" 2017-04-05 14:30:16 +02:00
Ales Pergl
63eeb96e71 Address cpplint issue "Do not use namespace using-directives. Use using-declarations instead. [build/namespaces] [5]" 2017-04-05 14:30:16 +02:00
Ales Pergl
20d0bda538 Address cpplint issue "Found C++ system header after other header. Should be: toast.h, c system, c++ system, other. [build/include_order] [4]" 2017-04-05 14:30:16 +02:00
Ales Pergl
33b4936a68 Address cpplint issue "Include the directory when naming .h files [build/include] [4]" 2017-04-05 14:30:15 +02:00
Ales Pergl
0bba5b9b41 Address cpplint issue "Lines should be <= 80 characters long [whitespace/line_length] [2]" 2017-04-05 14:30:15 +02:00
Ales Pergl
392d606848 Changed member variable naming style to snake case 2017-04-05 14:30:15 +02:00
Ales Pergl
fe05b66a6c Added desktop notifications implementation for Windows 7 (and earlier) 2017-04-05 14:30:15 +02:00