Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#5903 closed enhancement (fixed)

Proposed re-factor of mythweather code for units of measure

Reported by: wstewart@… Owned by: stuartm
Priority: minor Milestone: 0.22
Component: mythweather Version: head
Severity: low Keywords:
Cc: Ticket locked: no

Description

Proposed small reorganization of the mythweather code handling display of units of measure. Moves this to one common routine formatDataItem used for all weather screens.

The big advantage is that any of the possible weather variables can appear on any weather screen and will get units. This should also allow definitiion of an abitrary weather screen other than the standard current, 3day, etc.

Attachments (2)

mythweather.diff (4.2 KB) - added by wstewart@… 15 years ago.
mythweather.2.diff (10.1 KB) - added by wstewart@… 15 years ago.
Updated, see comment for changes

Download all attachments as: .zip

Change History (7)

Changed 15 years ago by wstewart@…

Attachment: mythweather.diff added

comment:1 Changed 15 years ago by Dibblah

Status: newassigned

Changed 15 years ago by wstewart@…

Attachment: mythweather.2.diff added

Updated, see comment for changes

comment:2 Changed 15 years ago by wstewart@…

New title: More fully utilize weather-screens.xml New Description: This patch does several things:

  • Remove currentconditions,3d and 6d code from Weatherscreens.cpp since this is now defined by weather-screens.xml
  • Re-factor and combine all the code handling units into one routine, formatDataItem.
  • allow theme to override default weather-screens.xml. For example a combined curent conditions and 3 day screen could be created. The default file will still be read even if the theme overrides. Therefore the theme should only define new screens and not modify the existing ones.

comment:3 Changed 15 years ago by stuartm

Status: assignedstarted

comment:4 Changed 15 years ago by stuartm

Resolution: fixed
Status: startedclosed

(In [20100]) Refactor mythweather to allow custom weather screens to be defined in weather-screens.xml. Patch from wstewart, closes #5903. I've only tested to make sure it doesn't break anything.

comment:5 Changed 15 years ago by stuartm

Milestone: unknown0.22
Note: See TracTickets for help on using tickets.