summary refs log tree commit diff stats
path: root/src/gtk2-prefs/win32util.h
blob: 8c194a1959e118b61a1a0e9d69e7d126acbb5e25 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/***************************************************************************
                          win32util.h  -  description
                             -------------------
    begin                : Tue Jan 14 2003
    copyright            : (C) 2003 by Alex Shaduri
    email                : alex_sh@land.ru
 ***************************************************************************/
#ifndef WIN32UTIL_H
#define WIN32UTIL_H

#ifdef _WIN32

#include <string>
#include "sys_win32.h"



std::string win32_get_registry_value_string(HKEY base, const std::string& keydir, const std::string& key);
void win32_set_registry_value_string(HKEY base, const std::string& keydir, const std::string& key, const std::string& value);




#endif //_WIN32

#endif // WIN32UTIL_H
pan>@lines = @_; for( @lines ) { if( /^\s*$/s ) { $_ = qq{"\\n"\n}; next; } if( /^\s*#/ ) { $_ = qq{"\\n"\n}; next; } s/\\/\\\\/g; # double the number of \'s s/"/\\"/g; s/^\s*/"/; s/\n/\\n"\n/; } return @lines; } for my $files ( [ "hexchat.pm.h", # output file "lib/HexChat.pm", # input files "lib/Xchat.pm", "lib/HexChat/Embed.pm", "lib/HexChat/List/Network.pm", "lib/HexChat/List/Network/Entry.pm", "lib/HexChat/List/Network/AutoJoin.pm", ], [ "irc.pm.h", # output file "lib/IRC.pm" # input file ] ) { my ($output,@inputs) = @$files; open my $header, ">", $output or die "Couldn't open '$output': $!"; print $header qq["BEGIN {\\n"\n]; for my $input ( @inputs ) { (my $trimmed = $input) =~ s{^lib/}{}; print $header qq["\$INC{'$trimmed'} = 'Compiled into the plugin.';\\n"\n]; } print $header qq["}\\n"\n]; for my $input ( @inputs ) { print $header qq["{\\n"\n]; print $header qq{"#line 1 \\"$input\\"\\n"\n}; print $header header( $input ); print $header qq["}\\n"\n]; } close $header; }