Issue 362

Here are some small changes from CPPCheck and also in some places I seen that some parameters could be declared const as they are not being changed.
This commit is contained in:
Shamari Campbell
2018-12-16 23:43:39 +00:00
parent dbd8a4a691
commit ddc38c3998
5 changed files with 18 additions and 14 deletions

View File

@@ -27,7 +27,7 @@ namespace nana
};
date(); ///< the initialized date is today.
date(const std::tm&);
explicit date(const std::tm&);
date(int year, int month, int day);
date operator - (int off) const;
@@ -44,8 +44,8 @@ namespace nana
void set(const std::tm&);
static int day_of_week(int year, int month, int day);
static unsigned year_days(unsigned year); ///< the number of days in the specified year.
static unsigned month_days(unsigned year, unsigned month); ///< the number of days in the specified month.
static unsigned year_days(const unsigned year); ///< the number of days in the specified year.
static unsigned month_days(const unsigned year, const unsigned month); ///< the number of days in the specified month.
static unsigned day_in_year(unsigned y, unsigned m, unsigned d); ///< Returns the index of the specified day in this year, at range[1, 365] or [1, 366]
private:
date _m_add(unsigned x) const;

View File

@@ -91,7 +91,7 @@ namespace nana
virtual void shortkey(graph_reference, const arg_keyboard&);
void filter_event(const event_code evt_code, const bool bDisabled);
void filter_event(const std::vector<event_code> evt_codes, const bool bDisabled);
void filter_event(const std::vector<event_code>& evt_codes, const bool bDisabled);
void filter_event(const event_filter_status& evt_all_states);
bool filter_event(const event_code evt_code);
event_filter_status filter_event();

View File

@@ -45,7 +45,7 @@ namespace nana
: public bground_factory_interface
{
public:
bground_transparent(std::size_t percent);
explicit bground_transparent(std::size_t percent);
private:
bground_interface* create() const override;
private: