GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Remove unused pointer to DisplayApp member variables by NeroBurner · Pull Request #2125 · InfiniTimeOrg/InfiniTime

Conversation

@NeroBurner

@NeroBurner NeroBurner commented Sep 18, 2024 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

In the screens that use DisplayApp *app and pass it to a child item, or use the reference just in the constructor. Afterwards the app member is not used. So remove it from the private member variables.

SettingDisplay.h actually never uses DisplayApp *app and the parameter could be removed from the constructor. I'd be happy about feedback whether or not to remove it.
Completely remove app parameter from SettingDisplay constructor as it is unused.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

ptman reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@NeroBurner NeroBurner added the maintenance Background work label Sep 18, 2024
@github-actions

github-actions Bot commented Sep 18, 2024 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Build size and comparison to main:

Section Size Difference
text 374136B -48B
data 948B 0B
bss 63480B 0B
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@NeroBurner
NeroBurner force-pushed the remove_unused_app_member branch from e61860b to d1a0377 Compare September 18, 2024 19:11
@NeroBurner

NeroBurner commented Sep 18, 2024

Copy link
Copy Markdown
Contributor Author

build error because of unused variable, removing app from constructor

 /__w/InfiniTime/InfiniTime/src/displayapp/screens/settings/SettingDisplay.cpp:27:68: error: unused parameter 'app' [-Werror=unused-parameter]
   27 | SettingDisplay::SettingDisplay(Pinetime::Applications::DisplayApp* app, Pinetime::Controllers::Settings& settingsController)
      |                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
cc1plus: all warnings being treated as errors
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@NeroBurner
Remove unused pointer to DisplayApp member variables
a202a3f
In the screens that use `DisplayApp *app` and pass it to a child item,
or use the reference just in the constructor. Afterwards the `app`
member is not used. So remove it from the private member variables.

Completely remove `app` parameter from `SettingDisplay` constructor as
it is unused.
@NeroBurner
NeroBurner force-pushed the remove_unused_app_member branch from d1a0377 to a202a3f Compare September 18, 2024 19:13
mark9064
mark9064 approved these changes Sep 18, 2024
View reviewed changes
@NeroBurner
NeroBurner requested a review from a team September 18, 2024 19:21
@NeroBurner NeroBurner added this to the 1.15.0 milestone Sep 19, 2024
FintasticMan
FintasticMan approved these changes Sep 29, 2024
View reviewed changes

@FintasticMan FintasticMan left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@NeroBurner
NeroBurner merged commit 3db4e01 into main Sep 29, 2024
@NeroBurner
NeroBurner deleted the remove_unused_app_member branch September 29, 2024 17:39
headblockhead added a commit to headblockhead/InfiniTime that referenced this pull request Oct 4, 2024
@headblockhead @NeroBurner @vkareh
vkareh:global-widget-config (#2)
0547480
* Remove unused pointer to DisplayApp member variables (InfiniTimeOrg#2125)

In the screens that use `DisplayApp *app` and pass it to a child item,
or use the reference just in the constructor. Afterwards the `app`
member is not used. So remove it from the private member variables.

Completely remove `app` parameter from `SettingDisplay` constructor as
it is unused.

* MusicService: add missing includes for TickType_t and xTaskGetTickCount (InfiniTimeOrg#2130)

Add `FreeRTOS.h` include for the directly used data type `TickType_t` in the header
and the function `xTaskGetTickCount` from FreeRTOS's `task.h`

* settings: Add global widget selection

Instead of each watch face implementing their own settings for which
widgets to display, we can have a global selection of widgets. All
watch faces can then determine whether it is enabled and so display it
in whichever way makes sense for that face.

Current widgets supported are heart rate, step counter, and weather.

* WatchFaceAnalog: Add configurable widgets

* WatchFaceAnalog: Add weather widget

---------

Co-authored-by: NeroBurner <[email protected]>
Co-authored-by: Victor Kareh <[email protected]>
headblockhead added a commit to headblockhead/InfiniTime that referenced this pull request Oct 4, 2024
@headblockhead @NeroBurner @vkareh
vkareh:battery-icon-colors (#5)
e84de3d
* Remove unused pointer to DisplayApp member variables (InfiniTimeOrg#2125)

In the screens that use `DisplayApp *app` and pass it to a child item,
or use the reference just in the constructor. Afterwards the `app`
member is not used. So remove it from the private member variables.

Completely remove `app` parameter from `SettingDisplay` constructor as
it is unused.

* MusicService: add missing includes for TickType_t and xTaskGetTickCount (InfiniTimeOrg#2130)

Add `FreeRTOS.h` include for the directly used data type `TickType_t` in the header
and the function `xTaskGetTickCount` from FreeRTOS's `task.h`

* BatteryIcon: Change color with charge percentage

---------

Co-authored-by: NeroBurner <[email protected]>
Co-authored-by: Victor Kareh <[email protected]>
headblockhead added a commit to headblockhead/InfiniTime that referenced this pull request Oct 4, 2024
@headblockhead @NeroBurner @JustScott
JustScott:improve_terminal_watchface_ui (#6)
deb979a
* Remove unused pointer to DisplayApp member variables (InfiniTimeOrg#2125)

In the screens that use `DisplayApp *app` and pass it to a child item,
or use the reference just in the constructor. Afterwards the `app`
member is not used. So remove it from the private member variables.

Completely remove `app` parameter from `SettingDisplay` constructor as
it is unused.

* MusicService: add missing includes for TickType_t and xTaskGetTickCount (InfiniTimeOrg#2130)

Add `FreeRTOS.h` include for the directly used data type `TickType_t` in the header
and the function `xTaskGetTickCount` from FreeRTOS's `task.h`

* Improved the Terminal Watchfaces UI

+ Reorder code to match the widgets order in the UI.

+ Use InfintimeTheme Colors instead of hardcoded hex values

+ Added a new InfinitimeTheme color: gray, using it to turn certain
  values gray when they contain no data

+ Implement @vkareh's [variable battery icon](InfiniTimeOrg#1964)
  color to the battery percentage text.

+ Replaced the 'You have mail.' notification message with the message
  '[1]+ Notify' to better fit the terminal lore.

---------

Co-authored-by: NeroBurner <[email protected]>
Co-authored-by: JustScott <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@mark9064 mark9064 mark9064 approved these changes
@FintasticMan FintasticMan FintasticMan approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

maintenance Background work

Projects

None yet

Milestone

1.15.0

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@NeroBurner @mark9064 @FintasticMan
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.