Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
L
libvncserver
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
rasky
libvncserver
Commits
d013b876
Commit
d013b876
authored
Mar 20, 2007
by
runge
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ssvnc: sync to 1.0.13 release.
parent
5e454662
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
150 additions
and
39 deletions
+150
-39
README
x11vnc/misc/enhanced_tightvnc_viewer/README
+32
-12
README.txt
x11vnc/misc/enhanced_tightvnc_viewer/Windows/README.txt
+18
-0
ssvnc.tcl
x11vnc/misc/enhanced_tightvnc_viewer/bin/util/ssvnc.tcl
+44
-1
build.unix
x11vnc/misc/enhanced_tightvnc_viewer/build.unix
+9
-2
_bundle
x11vnc/misc/enhanced_tightvnc_viewer/src/patches/_bundle
+1
-1
tight-vncviewer-full.patch
...ed_tightvnc_viewer/src/patches/tight-vncviewer-full.patch
+46
-23
No files found.
x11vnc/misc/enhanced_tightvnc_viewer/README
View file @
d013b876
...
@@ -22,17 +22,15 @@ See these sites and related ones for more information:
...
@@ -22,17 +22,15 @@ See these sites and related ones for more information:
http://www.chiark.greenend.org.uk/~sgtatham/putty/
http://www.chiark.greenend.org.uk/~sgtatham/putty/
http://sourceforge.net/projects/cotvnc/
http://sourceforge.net/projects/cotvnc/
Note: Some of the Windows binaries included contain cryptographic software
Note: Some of the binaries included contain cryptographic software that
that you may not be allowed to download, use, or redistribute. Please
you may not be allowed to download, use, or redistribute. Please check
check your situation first before downloading any of these bundles.
your situation first before downloading any of these bundles. See the
See the survey http://rechten.uvt.nl/koops/cryptolaw/index.htm for useful
survey http://rechten.uvt.nl/koops/cryptolaw/index.htm for useful
information. The Unix programs do not contain cryptographic software, but
information.
rather will make use of cryptographic libraries that are installed on your
Unix system. Depending on your circumstances you may still need to check.
All work done by Karl J. Runge in this project is
Copyright (c) 2006-2007 Karl J. Runge and is licensed under the GPL as
All work by Karl J. Runge in this project is Copyright (c) 2006 Karl J. Runge
described in the file COPYING in this directory.
and is licensed under the GPL as described in the file COPYING in this
directory.
All the files and information in this project are provided "AS IS"
All the files and information in this project are provided "AS IS"
without any warranty of any kind. Use them at your own risk.
without any warranty of any kind. Use them at your own risk.
...
@@ -52,7 +50,7 @@ The short name of the project is "ssvnc" for SSL/SSH VNC Viewer.
...
@@ -52,7 +50,7 @@ The short name of the project is "ssvnc" for SSL/SSH VNC Viewer.
It is a self-contained bundle, you could carry it around on, say,
It is a self-contained bundle, you could carry it around on, say,
a USB memory stick for secure VNC viewing from almost any machine,
a USB memory stick for secure VNC viewing from almost any machine,
Unix or Windows.
Unix
, Mac,
or Windows.
Features:
Features:
--------
--------
...
@@ -99,6 +97,8 @@ The enhanced TightVNC viewer features are:
...
@@ -99,6 +97,8 @@ The enhanced TightVNC viewer features are:
- Cursor alphablending with x11vnc at 32bpp (-alpha option)
- Cursor alphablending with x11vnc at 32bpp (-alpha option)
- Maintains its own BackingStore if the X server does not
- x11vnc's client-side caching -ncache method cropping option
- x11vnc's client-side caching -ncache method cropping option
(-ycrop n). This will "hide" the large pixel buffer cache
(-ycrop n). This will "hide" the large pixel buffer cache
below the actual display. Set to actual height or use -1 for
below the actual display. Set to actual height or use -1 for
...
@@ -188,8 +188,26 @@ Windows:
...
@@ -188,8 +188,26 @@ Windows:
You can make a Windows shortcut to this program if you want to.
You can make a Windows shortcut to this program if you want to.
See the Windows/README.txt for more info.
See the Windows/README.txt for more info.
Important Note for Windows Vista: One user reports that on Windows Vista
if you move or extract the "ssvnc" folder down to the "Program Files"
folder you will be prompted to do this as the Administrator. But then
when you start up ssvnc, as a regular user, it cannot create files in
that folder and so it fails to run properly. We recommend to not copy
or extract the "ssvnc" folder into "Program Files". Rather, extract
it to somewhere you have write permission (e.g. C:\ or your User dir)
and create a Shortcut to ssvnc.exe on the desktop.
If you must put a launcher file down in "Program Files", perhaps an
"ssvnc.bat" that looks like this:
C:
cd \ssvnc\Windows
ssvnc.exe
Bundle Info:
Bundle Info:
------------
------------
...
@@ -262,6 +280,8 @@ README is in, i.e "ssvnc") and like this:
...
@@ -262,6 +280,8 @@ README is in, i.e "ssvnc") and like this:
To use custom locations for libraries see the LDFLAGS_OS and CPPFLAGS_OS
To use custom locations for libraries see the LDFLAGS_OS and CPPFLAGS_OS
description at the top of the build.unix script.
description at the top of the build.unix script.
Feel free to ask us if you need help running ./build.unix
The programs:
The programs:
------------
------------
...
...
x11vnc/misc/enhanced_tightvnc_viewer/Windows/README.txt
View file @
d013b876
...
@@ -49,3 +49,21 @@ Misc:
...
@@ -49,3 +49,21 @@ Misc:
Also, the kill.exe and tlist.exe programs in the w98 directory
Also, the kill.exe and tlist.exe programs in the w98 directory
came from diagnostic tools ftp site of Microsoft's.
came from diagnostic tools ftp site of Microsoft's.
Important Note for Windows Vista: One user reports that on Windows Vista
if you move or extract the "ssvnc" folder down to the "Program Files"
folder you will be prompted to do this as the Administrator. But then
when you start up ssvnc, as a regular user, it cannot create files in
that folder and so it fails to run properly. We recommend to not copy
or extract the "ssvnc" folder into "Program Files". Rather, extract
it to somewhere you have write permission (e.g. C:\ or your User dir)
and create a Shortcut to ssvnc.exe on the desktop.
If you must put a launcher file down in "Program Files", perhaps an
"ssvnc.bat" that looks like this:
C:
cd \ssvnc\Windows
ssvnc.exe
x11vnc/misc/enhanced_tightvnc_viewer/bin/util/ssvnc.tcl
View file @
d013b876
...
@@ -883,6 +883,7 @@ proc get_ipconfig {} {
...
@@ -883,6 +883,7 @@ proc get_ipconfig {} {
append file
[
pid
]
append file
[
pid
]
append file
".txt"
append file
".txt"
# VF
catch
{[
exec
winipcfg /Batch
$file
]}
catch
{[
exec
winipcfg /Batch
$file
]}
if
[
file
exists
$file
]
{
if
[
file
exists
$file
]
{
...
@@ -984,6 +985,7 @@ proc windows_start_sound_daemon {file} {
...
@@ -984,6 +985,7 @@ proc windows_start_sound_daemon {file} {
global env
global env
global use_sound sound_daemon_local_cmd sound_daemon_local_start
global use_sound sound_daemon_local_cmd sound_daemon_local_start
# VF
regsub
{
\.
bat
}
$file
"snd.bat"
file2
regsub
{
\.
bat
}
$file
"snd.bat"
file2
set fh2
[
open
$file2
"w"
]
set fh2
[
open
$file2
"w"
]
...
@@ -1240,11 +1242,13 @@ proc launch_windows_ssh {hp file n} {
...
@@ -1240,11 +1242,13 @@ proc launch_windows_ssh {hp file n} {
set setup_cmds
[
ugly_setup_scripts pre
$tag
]
set setup_cmds
[
ugly_setup_scripts pre
$tag
]
if
{
$setup
_cmds !=
""
}
{
if
{
$setup
_cmds !=
""
}
{
# VF
regsub
{
\.
bat
}
$file
"pre.cmd"
file_pre_cmd
regsub
{
\.
bat
}
$file
"pre.cmd"
file_pre_cmd
set fh
[
open
$file
_pre_cmd
"w"
]
set fh
[
open
$file
_pre_cmd
"w"
]
puts
$fh
"
$setup
_cmds sleep 10; "
puts
$fh
"
$setup
_cmds sleep 10; "
close
$fh
close
$fh
# VF
regsub
{
\.
bat
}
$file
"pre.bat"
file_pre
regsub
{
\.
bat
}
$file
"pre.bat"
file_pre
set fh
[
open
$file
_pre
"w"
]
set fh
[
open
$file
_pre
"w"
]
set plink_str
"plink.exe -ssh -C -P
$ssh
_port -m
$file
_pre_cmd
$verb
-t"
set plink_str
"plink.exe -ssh -C -P
$ssh
_port -m
$file
_pre_cmd
$verb
-t"
...
@@ -1290,6 +1294,7 @@ proc launch_windows_ssh {hp file n} {
...
@@ -1290,6 +1294,7 @@ proc launch_windows_ssh {hp file n} {
set file_cmd
""
set file_cmd
""
if
{
$setup
_cmds !=
""
}
{
if
{
$setup
_cmds !=
""
}
{
# VF
regsub
{
\.
bat
}
$file
".cmd"
file_cmd
regsub
{
\.
bat
}
$file
".cmd"
file_cmd
set fh_cmd
[
open
$file
_cmd
"w"
]
set fh_cmd
[
open
$file
_cmd
"w"
]
...
@@ -1315,6 +1320,7 @@ proc launch_windows_ssh {hp file n} {
...
@@ -1315,6 +1320,7 @@ proc launch_windows_ssh {hp file n} {
windows_start_sound_daemon
$file
windows_start_sound_daemon
$file
}
}
# VF
set fh
[
open
$file
"w"
]
set fh
[
open
$file
"w"
]
if
{
$is
_win9x
}
{
if
{
$is
_win9x
}
{
puts
$fh
"cd
$pwd
"
puts
$fh
"cd
$pwd
"
...
@@ -1392,6 +1398,7 @@ proc launch_windows_ssh {hp file n} {
...
@@ -1392,6 +1398,7 @@ proc launch_windows_ssh {hp file n} {
if
{
$double
_ssh !=
""
}
{
if
{
$double
_ssh !=
""
}
{
set plink_str_double_ssh
"plink.exe -ssh -t
$pw
$double
_ssh
\"
echo sleep 60 ...; sleep 60; echo done.
\"
"
set plink_str_double_ssh
"plink.exe -ssh -t
$pw
$double
_ssh
\"
echo sleep 60 ...; sleep 60; echo done.
\"
"
# VF
regsub
{
\.
bat
}
$file
"dob.bat"
file_double
regsub
{
\.
bat
}
$file
"dob.bat"
file_double
set fhdouble
[
open
$file
_double
"w"
]
set fhdouble
[
open
$file
_double
"w"
]
puts
$fhdouble
$plink
_str_double_ssh
puts
$fhdouble
$plink
_str_double_ssh
...
@@ -2089,6 +2096,7 @@ proc fetch_cert {} {
...
@@ -2089,6 +2096,7 @@ proc fetch_cert {} {
global is_windows
global is_windows
set tmp
"/tmp/cert.hsh.
[
pid
]
"
set tmp
"/tmp/cert.hsh.
[
pid
]
"
if
{
$is
_windows
}
{
if
{
$is
_windows
}
{
# VF
set tmp cert.hsh
set tmp cert.hsh
}
}
set fh
""
set fh
""
...
@@ -2181,6 +2189,7 @@ proc fetch_cert_windows {hp} {
...
@@ -2181,6 +2189,7 @@ proc fetch_cert_windows {hp} {
set ossl
[
get_openssl
]
set ossl
[
get_openssl
]
update
update
# VF
set tin tmpin.txt
set tin tmpin.txt
set tou tmpout.txt
set tou tmpout.txt
set fh
""
set fh
""
...
@@ -2891,10 +2900,11 @@ proc launch {{hp ""}} {
...
@@ -2891,10 +2900,11 @@ proc launch {{hp ""}} {
}
}
}
}
# VF
set prefix
"stunnel-vnc"
set prefix
"stunnel-vnc"
set suffix
"conf"
set suffix
"conf"
if
{
$use
_ssh ||
$use
_sshssl
}
{
if
{
$use
_ssh ||
$use
_sshssl
}
{
set prefix
"plink
-
vnc"
set prefix
"plink
_
vnc"
set suffix
"bat"
set suffix
"bat"
}
}
...
@@ -3450,6 +3460,7 @@ emailAddress_max = 64
...
@@ -3450,6 +3460,7 @@ emailAddress_max = 64
global is_windows
global is_windows
if
{
$is
_windows
}
{
if
{
$is
_windows
}
{
# VF
set tmp
"cert.cfg"
set tmp
"cert.cfg"
}
else
{
}
else
{
set tmp
"/tmp/cert.cfg."
set tmp
"/tmp/cert.cfg."
...
@@ -7439,6 +7450,34 @@ proc set_options {} {
...
@@ -7439,6 +7450,34 @@ proc set_options {} {
focus .o
focus .o
}
}
proc
check_writable
{}
{
set test test
[
pid
]
.txt
catch
{
set
f
[
open
$test
"w"
];
puts
$f
"test"
;
close
$f
}
###catch
{
file
delete -force
$test
}
# testing.
if !
[
file
exists
$test
]
{
global env
if
[
info
exists env
(
HOME
)]
{
set dir
"
$env
(HOME)/ss_vnc/cache"
catch
{
file
mkdir
$dir
}
if !
[
file
exists
$dir
]
{
return
}
foreach f
[
glob
-type f * */* */*/*
]
{
set dest
"
$dir
/
$f
"
set dirn
[
file
dirname
$dest
]
catch
{
file
mkdir
$dirn
}
catch
{
file
copy -force --
$f
$dest
}
}
cd
$dir
###catch
{
set
f
[
open
$test
"w"
];
puts
$f
"test"
;
close
$f
}
}
}
else
{
catch
{
file
delete -force
$test
}
}
}
global
env
global
env
set
is_windows 0
set
is_windows 0
set
help_font
"-font fixed"
set
help_font
"-font fixed"
...
@@ -7454,6 +7493,10 @@ if {[regexp -nocase {Windows.9} $tcl_platform(os)]} {
...
@@ -7454,6 +7493,10 @@ if {[regexp -nocase {Windows.9} $tcl_platform(os)]} {
set is_win9x 0
set is_win9x 0
}
}
if
{
$is
_windows
}
{
check_writable
}
set
uname
""
set
uname
""
if
{
!
$is
_windows
}
{
if
{
!
$is
_windows
}
{
catch
{
set
uname
[
exec
uname
]}
catch
{
set
uname
[
exec
uname
]}
...
...
x11vnc/misc/enhanced_tightvnc_viewer/build.unix
View file @
d013b876
...
@@ -87,13 +87,16 @@ mkdir -p $tmp || exit 1
...
@@ -87,13 +87,16 @@ mkdir -p $tmp || exit 1
#
#
libs
=
"
$tmp
/libs"
libs
=
"
$tmp
/libs"
mkdir
-p
$libs
||
exit
1
mkdir
-p
$libs
||
exit
1
#
for liba in libz.a libjpeg.a libssl.a libcrypto.a
for
liba
in
libz.a libjpeg.a libssl.a libcrypto.a
for
liba
in
libz.a libjpeg.a
#
for liba in libz.a libjpeg.a
do
do
for
dir
in
/usr/lib /lib /usr/local/lib /usr/pkg/lib /usr/sfw/lib /usr/openwin/lib
for
dir
in
/usr/lib /lib /usr/local/lib /usr/pkg/lib /usr/sfw/lib /usr/openwin/lib
do
do
if
[
"
$name
"
=
"Linux.x86_64"
-o
"
$name
"
=
"Linux.ppc64"
]
;
then
if
[
"
$name
"
=
"Linux.x86_64"
-o
"
$name
"
=
"Linux.ppc64"
]
;
then
dir64
=
`
echo
"
$dir
"
|
sed
-e
's,lib,lib64,'
`
dir64
=
`
echo
"
$dir
"
|
sed
-e
's,lib,lib64,'
`
if
[
-d
$dir64
]
;
then
dir
=
$dir64
fi
fi
fi
try
=
"
$dir
/
$liba
"
try
=
"
$dir
/
$liba
"
if
[
-f
$try
]
;
then
if
[
-f
$try
]
;
then
...
@@ -128,6 +131,10 @@ END
...
@@ -128,6 +131,10 @@ END
fi
fi
fi
fi
if
[
-d
/var/tmp/LIBS
]
;
then
LDFLAGS_OS
=
"
$LDFLAGS_OS
-L/var/tmp/LIBS"
fi
if
[
`
uname
`
=
"SunOS"
]
;
then
if
[
`
uname
`
=
"SunOS"
]
;
then
LDFLAGS_OS
=
"
$LDFLAGS_OS
-L/usr/sfw/lib -R/usr/sfw/lib"
LDFLAGS_OS
=
"
$LDFLAGS_OS
-L/usr/sfw/lib -R/usr/sfw/lib"
CPPFLAGS_OS
=
"
$CPPFLAGS_OS
-I /usr/sfw/include"
CPPFLAGS_OS
=
"
$CPPFLAGS_OS
-I /usr/sfw/include"
...
...
x11vnc/misc/enhanced_tightvnc_viewer/src/patches/_bundle
View file @
d013b876
#!/bin/sh
#!/bin/sh
rm
-rf
./src/tmp/
*
||
exit
1
rm
-rf
./src/tmp/
*
||
exit
1
vers
=
1.0.1
2
vers
=
1.0.1
3
cd
..
||
exit
1
cd
..
||
exit
1
...
...
x11vnc/misc/enhanced_tightvnc_viewer/src/patches/tight-vncviewer-full.patch
View file @
d013b876
...
@@ -1128,7 +1128,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cp_it vnc_unixsrc/vncviewer/c
...
@@ -1128,7 +1128,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cp_it vnc_unixsrc/vncviewer/c
+ls -l ./vncviewer $dest /dist/src/apps/VNC/etc/libvncserver_cvs/expts/etv/ssvnc/bin/Linux.i686/vncviewer
+ls -l ./vncviewer $dest /dist/src/apps/VNC/etc/libvncserver_cvs/expts/etv/ssvnc/bin/Linux.i686/vncviewer
diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewer/cursor.c
diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewer/cursor.c
--- vnc_unixsrc.orig/vncviewer/cursor.c 2003-01-15 04:46:52.000000000 -0500
--- vnc_unixsrc.orig/vncviewer/cursor.c 2003-01-15 04:46:52.000000000 -0500
+++ vnc_unixsrc/vncviewer/cursor.c 2007-0
2-08 18:46:24.000000000 -05
00
+++ vnc_unixsrc/vncviewer/cursor.c 2007-0
3-17 22:48:34.000000000 -04
00
@@ -39,7 +39,7 @@
@@ -39,7 +39,7 @@
static Bool prevSoftCursorSet = False;
static Bool prevSoftCursorSet = False;
...
@@ -1197,7 +1197,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1197,7 +1197,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
free(buf);
free(buf);
return False;
return False;
}
}
@@ -429,41 +435,
51
@@
@@ -429,41 +435,
63
@@
rcLockY + rcLockHeight > rcCursorY - rcHotY);
rcLockY + rcLockHeight > rcCursorY - rcHotY);
}
}
...
@@ -1252,6 +1252,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1252,6 +1252,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
+ if (oper == OPER_SAVE) {
+ if (oper == OPER_SAVE) {
+ /* Save screen area in memory. */
+ /* Save screen area in memory. */
+//fprintf(stderr, "OPER_SAVE\n");
+//fprintf(stderr, "OPER_SAVE\n");
+#if 0
#ifdef MITSHM
#ifdef MITSHM
- if (appData.useShm)
- if (appData.useShm)
- XSync(dpy, False);
- XSync(dpy, False);
...
@@ -1267,17 +1268,28 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1267,17 +1268,28 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
+ {
+ {
+ XSync(dpy, False);
+ XSync(dpy, False);
+ }
+ }
+ XCopyArea(dpy, desktopWin, rcSavedArea, gc, x, y, w, h, 0, 0);
+#endif
+ if (appData.useBackingstore) {
+ XSync(dpy, False);
+ XCopyArea(dpy, desktopWin, rcSavedArea, gc, x, y, w, h, 0, 0);
+ } else {
+ XPutImage(dpy, rcSavedArea, gc, image, x, y, 0, 0, w, h);
+ }
+ } else {
+ } else {
+//fprintf(stderr, "OPER_RESTORE\n");
+//fprintf(stderr, "OPER_RESTORE\n");
+ /* Restore screen area. */
+ /* Restore screen area. */
+ XCopyArea(dpy, rcSavedArea, desktopWin, gc, 0, 0, w, h, x, y);
+ if (appData.useBackingstore) {
+ XGetSubImage(dpy, rcSavedArea, 0, 0, w, h, AllPlanes, ZPixmap, image, x, y);
+ XCopyArea(dpy, rcSavedArea, desktopWin, gc, 0, 0, w, h, x, y);
+ XGetSubImage(dpy, rcSavedArea, 0, 0, w, h, AllPlanes, ZPixmap, image, x, y);
+ } else {
+ XCopyArea(dpy, rcSavedArea, desktopWin, gc, 0, 0, w, h, x, y);
+ XGetSubImage(dpy, rcSavedArea, 0, 0, w, h, AllPlanes, ZPixmap, image, x, y);
+ }
+ }
+ }
}
}
static void SoftCursorDraw(void)
static void SoftCursorDraw(void)
@@ -472,6 +
488
,139 @@
@@ -472,6 +
500
,139 @@
int offset, bytesPerPixel;
int offset, bytesPerPixel;
char *pos;
char *pos;
...
@@ -1299,10 +1311,10 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1299,10 +1311,10 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
+ if (alphablend && bytesPerPixel == 4) {
+ if (alphablend && bytesPerPixel == 4) {
+ unsigned long pixel, put, *upos, *upix;
+ unsigned long pixel, put, *upos, *upix;
+ int got_alpha = 0, rsX, rsY, rsW, rsH;
+ int got_alpha = 0, rsX, rsY, rsW, rsH;
+ static XImage *image = NULL;
+ static XImage *
alpha_
image = NULL;
+ static int iwidth = 128;
+ static int iwidth = 128;
+
+
+ if (! image) {
+ if (!
alpha_
image) {
+ /* watch out for tiny fb (rare) */
+ /* watch out for tiny fb (rare) */
+ if (iwidth > si.framebufferWidth) {
+ if (iwidth > si.framebufferWidth) {
+ iwidth = si.framebufferWidth;
+ iwidth = si.framebufferWidth;
...
@@ -1312,7 +1324,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1312,7 +1324,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
+ }
+ }
+
+
+ /* initialize an XImage with a chunk of desktopWin */
+ /* initialize an XImage with a chunk of desktopWin */
+ image = XGetImage(dpy, desktopWin, 0, 0, iwidth, iwidth,
+
alpha_
image = XGetImage(dpy, desktopWin, 0, 0, iwidth, iwidth,
+ AllPlanes, ZPixmap);
+ AllPlanes, ZPixmap);
+ }
+ }
+
+
...
@@ -1343,8 +1355,8 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1343,8 +1355,8 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
+
+
+ /* load the saved fb patch in to image (faster way?) */
+ /* load the saved fb patch in to image (faster way?) */
+ XGetSubImage(dpy, rcSavedArea, 0, 0, rcWidth, rcHeight,
+ XGetSubImage(dpy, rcSavedArea, 0, 0, rcWidth, rcHeight,
+ AllPlanes, ZPixmap, image, 0, 0);
+ AllPlanes, ZPixmap,
alpha_
image, 0, 0);
+ upix = (unsigned long *)image->data;
+ upix = (unsigned long *)
alpha_
image->data;
+
+
+ /* if the richcursor is clipped, the fb patch will be smaller */
+ /* if the richcursor is clipped, the fb patch will be smaller */
+ rsW = rcWidth;
+ rsW = rcWidth;
...
@@ -1417,8 +1429,11 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1417,8 +1429,11 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
bytesPerPixel = myFormat.bitsPerPixel / 8;
bytesPerPixel = myFormat.bitsPerPixel / 8;
/* FIXME: Speed optimization is possible. */
/* FIXME: Speed optimization is possible. */
@@ -492,23 +641,23 @@
@@ -490,25 +651,26 @@
}
}
}
}
+ XSync(dpy, False);
}
}
-static void FreeSoftCursor(void)
-static void FreeSoftCursor(void)
...
@@ -1457,7 +1472,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
...
@@ -1457,7 +1472,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/cursor.c vnc_unixsrc/vncviewe
-
-
diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncviewer/desktop.c
diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncviewer/desktop.c
--- vnc_unixsrc.orig/vncviewer/desktop.c 2004-05-28 13:29:29.000000000 -0400
--- vnc_unixsrc.orig/vncviewer/desktop.c 2004-05-28 13:29:29.000000000 -0400
+++ vnc_unixsrc/vncviewer/desktop.c 2007-03-
01 21:05:47.000000000 -05
00
+++ vnc_unixsrc/vncviewer/desktop.c 2007-03-
17 23:31:56.000000000 -04
00
@@ -28,21 +28,28 @@
@@ -28,21 +28,28 @@
#include <X11/extensions/XShm.h>
#include <X11/extensions/XShm.h>
#endif
#endif
...
@@ -1771,7 +1786,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1771,7 +1786,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
/*
/*
* DesktopInitAfterRealization does things which require the X windows to
* DesktopInitAfterRealization does things which require the X windows to
* exist. It creates some GCs and sets the dot cursor.
* exist. It creates some GCs and sets the dot cursor.
@@ -114,34 +306,10
0
@@
@@ -114,34 +306,10
8
@@
void
void
DesktopInitAfterRealization()
DesktopInitAfterRealization()
{
{
...
@@ -1820,6 +1835,14 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1820,6 +1835,14 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
+ NULL, 0);
+ NULL, 0);
+
+
+ if (appData.useBackingstore) {
+ if (appData.useBackingstore) {
+ Screen *s = DefaultScreenOfDisplay(dpy);
+ if (DoesBackingStore(s) != Always) {
+ fprintf(stderr, "X server does not do backingstore, disabling it.\n");
+ appData.useBackingstore = False;
+ }
+ }
+
+ if (appData.useBackingstore) {
+ XtVaGetApplicationResources(desktop, (XtPointer)&attr.backing_store,
+ XtVaGetApplicationResources(desktop, (XtPointer)&attr.backing_store,
+ desktopBackingStoreResources, 1, NULL);
+ desktopBackingStoreResources, 1, NULL);
+ valuemask |= CWBackingStore;
+ valuemask |= CWBackingStore;
...
@@ -1834,8 +1857,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1834,8 +1857,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
+ valuemask |= CWCursor;
+ valuemask |= CWCursor;
+ }
+ }
+ bogoCursor = XCreateFontCursor(dpy, XC_bogosity);
+ bogoCursor = XCreateFontCursor(dpy, XC_bogosity);
+
- XChangeWindowAttributes(dpy, desktopWin, valuemask, &attr);
+ XChangeWindowAttributes(dpy, desktopWin, valuemask, &attr);
+ XChangeWindowAttributes(dpy, desktopWin, valuemask, &attr);
+ if (XGetWindowAttributes(dpy, desktopWin, &gattr)) {
+ if (XGetWindowAttributes(dpy, desktopWin, &gattr)) {
+ fprintf(stderr, "desktopWin backingstore: %d save_under: %d\n", gattr.backing_store, gattr.save_under);
+ fprintf(stderr, "desktopWin backingstore: %d save_under: %d\n", gattr.backing_store, gattr.save_under);
...
@@ -1851,7 +1873,8 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1851,7 +1873,8 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
+{
+{
+ XSetWindowAttributes attr;
+ XSetWindowAttributes attr;
+ unsigned long valuemask;
+ unsigned long valuemask;
+
- XChangeWindowAttributes(dpy, desktopWin, valuemask, &attr);
+ if (dotCursor == None) {
+ if (dotCursor == None) {
+ dotCursor = CreateDotCursor();
+ dotCursor = CreateDotCursor();
+ }
+ }
...
@@ -1899,7 +1922,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1899,7 +1922,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
}
}
@@ -152,39 +41
0
,53 @@
@@ -152,39 +41
8
,53 @@
static void
static void
HandleBasicDesktopEvent(Widget w, XtPointer ptr, XEvent *ev, Boolean *cont)
HandleBasicDesktopEvent(Widget w, XtPointer ptr, XEvent *ev, Boolean *cont)
{
{
...
@@ -1974,7 +1997,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1974,7 +1997,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
}
}
@@ -201,6 +4
73
,9 @@
@@ -201,6 +4
81
,9 @@
* button2 down, 3 for both, etc).
* button2 down, 3 for both, etc).
*/
*/
...
@@ -1984,7 +2007,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1984,7 +2007,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
void
void
SendRFBEvent(Widget w, XEvent *ev, String *params, Cardinal *num_params)
SendRFBEvent(Widget w, XEvent *ev, String *params, Cardinal *num_params)
{
{
@@ -213,6 +4
88
,13 @@
@@ -213,6 +4
96
,13 @@
return;
return;
}
}
...
@@ -1998,7 +2021,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -1998,7 +2021,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
if (appData.viewOnly) return;
if (appData.viewOnly) return;
if (*num_params != 0) {
if (*num_params != 0) {
@@ -332,23 +6
14
,112 @@
@@ -332,23 +6
22
,112 @@
static Cursor
static Cursor
CreateDotCursor()
CreateDotCursor()
{
{
...
@@ -2127,7 +2150,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -2127,7 +2150,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
}
}
@@ -359,38 +73
0
,35 @@
@@ -359,38 +73
8
,35 @@
void
void
CopyDataToScreen(char *buf, int x, int y, int width, int height)
CopyDataToScreen(char *buf, int x, int y, int width, int height)
{
{
...
@@ -2193,7 +2216,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
...
@@ -2193,7 +2216,7 @@ diff -Naur -X ./exclude vnc_unixsrc.orig/vncviewer/desktop.c vnc_unixsrc/vncview
}
}
@@ -401,62 +7
69
,175 @@
@@ -401,62 +7
77
,175 @@
static void
static void
CopyBGR233ToScreen(CARD8 *buf, int x, int y, int width, int height)
CopyBGR233ToScreen(CARD8 *buf, int x, int y, int width, int height)
{
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment