Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

#5773 closed defect (fixed)

libmythdb could be more efficient about using QString

Reported by: Erik Hovland <erik@…> Owned by: Isaac Richards
Priority: trivial Milestone: unknown
Component: mythtv Version: head
Severity: low Keywords:
Cc: Ticket locked: no

Description

QString usage can be streamlined a bit by using single chars instead of single value strings, using clear() instead of assignment to null and using isEmpty() instead of checking against "".

Attachments (2)

libs_libmythdb-krazy2-single-char-operations.patch (14.0 KB) - added by Erik Hovland <erik@…> 16 years ago.
Uses single char instead of single value string
libs_libmythdb-krazy2-QString-compare.patch (4.6 KB) - added by Erik Hovland <erik@…> 16 years ago.
Uses clear() instead of null assignment and uses isEmpty() instead of == ""

Download all attachments as: .zip

Change History (6)

Changed 16 years ago by Erik Hovland <erik@…>

Uses single char instead of single value string

Changed 16 years ago by Erik Hovland <erik@…>

Uses clear() instead of null assignment and uses isEmpty() instead of == ""

comment:1 Changed 16 years ago by Janne Grunau

(In [18576]) Use single char instead of single value string for efficiency

Refs #5773 From: Erik Hovland <erik hovland org>

comment:2 Changed 16 years ago by Janne Grunau

(In [18577]) replaces QString::replace(regexp, "") with QString::remove(regexp)

Refs #5773 From: Erik Hovland <erik hovland org>

comment:3 Changed 16 years ago by Janne Grunau

Resolution: fixed
Status: newclosed

(In [18578]) Use isEmpty() instead of == "" and clear() instead of null assignment for QStrings

Fixes #5773 From: Erik Hovland <erik@…>

comment:4 Changed 16 years ago by Nigel

(In [18694]) Remove duplicated plugin-running code, make globals static, tidy QString usage (inspired by Erik. See #5773).

Note: See TracTickets for help on using tickets.