mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Modified cCharSetConv so that it can be used to convert from "whatever VDR uses" to a given code
This commit is contained in:
parent
1bb58100b0
commit
d8d65c7536
@ -1688,6 +1688,8 @@ Joachim Wilke <vdr@joachim-wilke.de>
|
||||
for reporting a problem with cStatus::MsgOsdTextItem() being called without a text
|
||||
for reporting a missing install-i18n in the install target in the Makefile
|
||||
for adding a missing 'const' to cRecording::FramesPerSecond()
|
||||
for modifying cCharSetConv so that it can be used to convert from "whatever VDR uses"
|
||||
to a given code
|
||||
|
||||
Sascha Klek <sklek@gmx.de>
|
||||
for reporting a problem with the '0' key in the "Day" item of the "Timers" menu
|
||||
|
5
HISTORY
5
HISTORY
@ -6197,7 +6197,7 @@ Video Disk Recorder Revision History
|
||||
- Fixed the default value for "Pause key handling" in the MANUAL (reported by
|
||||
Diego Pierotto).
|
||||
|
||||
2009-12-20: Version 1.7.11
|
||||
2009-12-23: Version 1.7.11
|
||||
|
||||
- Fixed resetting the file size when regenerating the index file.
|
||||
- The new function cDevice::PatPmtParser() can be used in derived devices to access
|
||||
@ -6220,3 +6220,6 @@ Video Disk Recorder Revision History
|
||||
- Some fixes to dvbspu.[hc] (thanks to Johann Friedrichs).
|
||||
- Fixed a busy loop when moving editing marks (thanks to Johann Friedrichs).
|
||||
- Updated sources.conf (thanks to Derek Kelly).
|
||||
- Modified cCharSetConv so that it can be used to convert from "whatever VDR uses"
|
||||
to a given code (thanks to Joachim Wilke).
|
||||
|
||||
|
6
tools.c
6
tools.c
@ -4,7 +4,7 @@
|
||||
* See the main source file 'vdr.c' for copyright information and
|
||||
* how to reach the author.
|
||||
*
|
||||
* $Id: tools.c 2.5 2009/12/06 12:19:56 kls Exp $
|
||||
* $Id: tools.c 2.6 2009/12/23 15:12:15 kls Exp $
|
||||
*/
|
||||
|
||||
#include "tools.h"
|
||||
@ -769,10 +769,10 @@ char *cCharSetConv::systemCharacterTable = NULL;
|
||||
cCharSetConv::cCharSetConv(const char *FromCode, const char *ToCode)
|
||||
{
|
||||
if (!FromCode)
|
||||
FromCode = systemCharacterTable;
|
||||
FromCode = systemCharacterTable ? systemCharacterTable : "UTF-8";
|
||||
if (!ToCode)
|
||||
ToCode = "UTF-8";
|
||||
cd = (FromCode && ToCode) ? iconv_open(ToCode, FromCode) : (iconv_t)-1;
|
||||
cd = iconv_open(ToCode, FromCode);
|
||||
result = NULL;
|
||||
length = 0;
|
||||
}
|
||||
|
5
tools.h
5
tools.h
@ -4,7 +4,7 @@
|
||||
* See the main source file 'vdr.c' for copyright information and
|
||||
* how to reach the author.
|
||||
*
|
||||
* $Id: tools.h 2.3 2009/12/06 11:24:12 kls Exp $
|
||||
* $Id: tools.h 2.4 2009/12/23 15:14:39 kls Exp $
|
||||
*/
|
||||
|
||||
#ifndef __TOOLS_H
|
||||
@ -142,7 +142,8 @@ private:
|
||||
public:
|
||||
cCharSetConv(const char *FromCode = NULL, const char *ToCode = NULL);
|
||||
///< Sets up a character set converter to convert from FromCode to ToCode.
|
||||
///< If FromCode is NULL, the previously set systemCharacterTable is used.
|
||||
///< If FromCode is NULL, the previously set systemCharacterTable is used
|
||||
///< (or "UTF-8" if no systemCharacterTable has been set).
|
||||
///< If ToCode is NULL, "UTF-8" is used.
|
||||
~cCharSetConv();
|
||||
const char *Convert(const char *From, char *To = NULL, size_t ToLength = 0);
|
||||
|
Loading…
Reference in New Issue
Block a user