aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/kdrive/src
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/kdrive/src')
-rw-r--r--xorg-server/hw/kdrive/src/Makefile.am14
-rw-r--r--xorg-server/hw/kdrive/src/Makefile.in171
-rw-r--r--xorg-server/hw/kdrive/src/kcmap.c3
-rw-r--r--xorg-server/hw/kdrive/src/kdrive.c81
-rw-r--r--xorg-server/hw/kdrive/src/kdrive.h20
-rw-r--r--xorg-server/hw/kdrive/src/kinfo.c2
-rw-r--r--xorg-server/hw/kdrive/src/kinput.c343
7 files changed, 181 insertions, 453 deletions
diff --git a/xorg-server/hw/kdrive/src/Makefile.am b/xorg-server/hw/kdrive/src/Makefile.am
index 792f64a4d..7ac23c2aa 100644
--- a/xorg-server/hw/kdrive/src/Makefile.am
+++ b/xorg-server/hw/kdrive/src/Makefile.am
@@ -4,13 +4,7 @@ INCLUDES = \
AM_CFLAGS = -DHAVE_DIX_CONFIG_H
-noinst_LIBRARIES = libkdrive.a libkdrivestubs.a
-
-if KDRIVE_HW
-KDRIVE_HW_SOURCES = \
- vga.c \
- vga.h
-endif
+noinst_LTLIBRARIES = libkdrive.la libkdrivestubs.la
if XV
KDRIVE_XV_SOURCES = \
@@ -18,7 +12,7 @@ KDRIVE_XV_SOURCES = \
kxv.h
endif
-libkdrive_a_SOURCES = \
+libkdrive_la_SOURCES = \
fourcc.h \
kcmap.c \
kcurscol.c \
@@ -26,13 +20,11 @@ libkdrive_a_SOURCES = \
kdrive.h \
kinfo.c \
kinput.c \
- kkeymap.c \
kmap.c \
kmode.c \
kshadow.c \
$(KDRIVE_XV_SOURCES) \
- $(KDRIVE_HW_SOURCES) \
$(top_srcdir)/mi/miinitext.c
-libkdrivestubs_a_SOURCES = \
+libkdrivestubs_la_SOURCES = \
$(top_srcdir)/fb/fbcmap_mi.c
diff --git a/xorg-server/hw/kdrive/src/Makefile.in b/xorg-server/hw/kdrive/src/Makefile.in
index 1b10fce31..cc604d2c4 100644
--- a/xorg-server/hw/kdrive/src/Makefile.in
+++ b/xorg-server/hw/kdrive/src/Makefile.in
@@ -37,8 +37,11 @@ host_triplet = @host@
subdir = hw/kdrive/src
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \
- $(top_srcdir)/configure.ac
+am__aclocal_m4_deps = $(top_srcdir)/m4/ac_define_dir.m4 \
+ $(top_srcdir)/m4/dolt.m4 $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/m4/shave.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@@ -48,28 +51,23 @@ CONFIG_HEADER = $(top_builddir)/include/do-not-use-config.h \
$(top_builddir)/include/xorg-config.h \
$(top_builddir)/include/xkb-config.h \
$(top_builddir)/include/xwin-config.h \
- $(top_builddir)/include/kdrive-config.h
+ $(top_builddir)/include/kdrive-config.h \
+ $(top_builddir)/include/version-config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
-LIBRARIES = $(noinst_LIBRARIES)
-ARFLAGS = cru
-libkdrive_a_AR = $(AR) $(ARFLAGS)
-libkdrive_a_LIBADD =
-am__libkdrive_a_SOURCES_DIST = fourcc.h kcmap.c kcurscol.c kdrive.c \
- kdrive.h kinfo.c kinput.c kkeymap.c kmap.c kmode.c kshadow.c \
- kxv.c kxv.h vga.c vga.h $(top_srcdir)/mi/miinitext.c
-@XV_TRUE@am__objects_1 = kxv.$(OBJEXT)
-@KDRIVE_HW_TRUE@am__objects_2 = vga.$(OBJEXT)
-am_libkdrive_a_OBJECTS = kcmap.$(OBJEXT) kcurscol.$(OBJEXT) \
- kdrive.$(OBJEXT) kinfo.$(OBJEXT) kinput.$(OBJEXT) \
- kkeymap.$(OBJEXT) kmap.$(OBJEXT) kmode.$(OBJEXT) \
- kshadow.$(OBJEXT) $(am__objects_1) $(am__objects_2) \
- miinitext.$(OBJEXT)
-libkdrive_a_OBJECTS = $(am_libkdrive_a_OBJECTS)
-libkdrivestubs_a_AR = $(AR) $(ARFLAGS)
-libkdrivestubs_a_LIBADD =
-am_libkdrivestubs_a_OBJECTS = fbcmap_mi.$(OBJEXT)
-libkdrivestubs_a_OBJECTS = $(am_libkdrivestubs_a_OBJECTS)
+LTLIBRARIES = $(noinst_LTLIBRARIES)
+libkdrive_la_LIBADD =
+am__libkdrive_la_SOURCES_DIST = fourcc.h kcmap.c kcurscol.c kdrive.c \
+ kdrive.h kinfo.c kinput.c kmap.c kmode.c kshadow.c kxv.c kxv.h \
+ $(top_srcdir)/mi/miinitext.c
+@XV_TRUE@am__objects_1 = kxv.lo
+am_libkdrive_la_OBJECTS = kcmap.lo kcurscol.lo kdrive.lo kinfo.lo \
+ kinput.lo kmap.lo kmode.lo kshadow.lo $(am__objects_1) \
+ miinitext.lo
+libkdrive_la_OBJECTS = $(am_libkdrive_la_OBJECTS)
+libkdrivestubs_la_LIBADD =
+am_libkdrivestubs_la_OBJECTS = fbcmap_mi.lo
+libkdrivestubs_la_OBJECTS = $(am_libkdrivestubs_la_OBJECTS)
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/include
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
@@ -80,9 +78,9 @@ CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
$(LDFLAGS) -o $@
-SOURCES = $(libkdrive_a_SOURCES) $(libkdrivestubs_a_SOURCES)
-DIST_SOURCES = $(am__libkdrive_a_SOURCES_DIST) \
- $(libkdrivestubs_a_SOURCES)
+SOURCES = $(libkdrive_la_SOURCES) $(libkdrivestubs_la_SOURCES)
+DIST_SOURCES = $(am__libkdrive_la_SOURCES_DIST) \
+ $(libkdrivestubs_la_SOURCES)
ETAGS = etags
CTAGS = ctags
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -91,6 +89,7 @@ ADMIN_MAN_DIR = @ADMIN_MAN_DIR@
ADMIN_MAN_SUFFIX = @ADMIN_MAN_SUFFIX@
ALLOCA = @ALLOCA@
AMTAR = @AMTAR@
+AM_MAKEFLAGS = @AM_MAKEFLAGS@
APPLE_APPLICATIONS_DIR = @APPLE_APPLICATIONS_DIR@
APPLE_APPLICATION_ID = @APPLE_APPLICATION_ID@
APPLE_APPLICATION_NAME = @APPLE_APPLICATION_NAME@
@@ -111,9 +110,12 @@ CCASDEPMODE = @CCASDEPMODE@
CCASFLAGS = @CCASFLAGS@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
+CHANGELOG_CMD = @CHANGELOG_CMD@
COMPILEDDEFAULTFONTPATH = @COMPILEDDEFAULTFONTPATH@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
+CWARNFLAGS = @CWARNFLAGS@
+CXX = @CXX@
CYGPATH_W = @CYGPATH_W@
DARWIN_LIBS = @DARWIN_LIBS@
DBUS_CFLAGS = @DBUS_CFLAGS@
@@ -142,7 +144,9 @@ DRIPROTO_CFLAGS = @DRIPROTO_CFLAGS@
DRIPROTO_LIBS = @DRIPROTO_LIBS@
DRIVER_MAN_DIR = @DRIVER_MAN_DIR@
DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@
+DRI_CFLAGS = @DRI_CFLAGS@
DRI_DRIVER_PATH = @DRI_DRIVER_PATH@
+DRI_LIBS = @DRI_LIBS@
DSYMUTIL = @DSYMUTIL@
DTRACE = @DTRACE@
DUMPBIN = @DUMPBIN@
@@ -151,9 +155,13 @@ ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
+F77 = @F77@
+FC = @FC@
FGREP = @FGREP@
FILE_MAN_DIR = @FILE_MAN_DIR@
FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@
+GLIB_CFLAGS = @GLIB_CFLAGS@
+GLIB_LIBS = @GLIB_LIBS@
GLX_ARCH_DEFINES = @GLX_ARCH_DEFINES@
GLX_DEFINES = @GLX_DEFINES@
GL_CFLAGS = @GL_CFLAGS@
@@ -192,12 +200,13 @@ LTCOMPILE = @LTCOMPILE@
LTCXXCOMPILE = @LTCXXCOMPILE@
LTLIBOBJS = @LTLIBOBJS@
MAINT = @MAINT@
+MAIN_LIB = @MAIN_LIB@
+MAKEFLAGS = @MAKEFLAGS@
MAKEINFO = @MAKEINFO@
MAKE_HTML = @MAKE_HTML@
MAKE_PDF = @MAKE_PDF@
MAKE_PS = @MAKE_PS@
MAKE_TEXT = @MAKE_TEXT@
-MESA_SOURCE = @MESA_SOURCE@
MISC_MAN_DIR = @MISC_MAN_DIR@
MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@
MKDIR_P = @MKDIR_P@
@@ -217,7 +226,6 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
-PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PCIACCESS_CFLAGS = @PCIACCESS_CFLAGS@
@@ -227,6 +235,7 @@ PERL = @PERL@
PKG_CONFIG = @PKG_CONFIG@
PROJECTROOT = @PROJECTROOT@
PS2PDF = @PS2PDF@
+Q = @Q@
RANLIB = @RANLIB@
RAWCPP = @RAWCPP@
RAWCPPFLAGS = @RAWCPPFLAGS@
@@ -240,11 +249,10 @@ STRIP = @STRIP@
TSLIB_CFLAGS = @TSLIB_CFLAGS@
TSLIB_LIBS = @TSLIB_LIBS@
UTILS_SYS_LIBS = @UTILS_SYS_LIBS@
-VENDOR_MAN_VERSION = @VENDOR_MAN_VERSION@
-VENDOR_NAME = @VENDOR_NAME@
+V = @V@
VENDOR_NAME_SHORT = @VENDOR_NAME_SHORT@
-VENDOR_RELEASE = @VENDOR_RELEASE@
VERSION = @VERSION@
+WINDRES = @WINDRES@
X11EXAMPLES_DEP_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@
X11EXAMPLES_DEP_LIBS = @X11EXAMPLES_DEP_LIBS@
XDMCP_CFLAGS = @XDMCP_CFLAGS@
@@ -280,6 +288,7 @@ XORG_OS_SUBDIR = @XORG_OS_SUBDIR@
XORG_SYS_LIBS = @XORG_SYS_LIBS@
XPBPROXY_CFLAGS = @XPBPROXY_CFLAGS@
XPBPROXY_LIBS = @XPBPROXY_LIBS@
+XQUARTZ_SPARKLE = @XQUARTZ_SPARKLE@
XRESEXAMPLES_DEP_CFLAGS = @XRESEXAMPLES_DEP_CFLAGS@
XRESEXAMPLES_DEP_LIBS = @XRESEXAMPLES_DEP_LIBS@
XSDL_INCS = @XSDL_INCS@
@@ -304,7 +313,6 @@ YFLAGS = @YFLAGS@
__XCONFIGFILE__ = @__XCONFIGFILE__@
abi_ansic = @abi_ansic@
abi_extension = @abi_extension@
-abi_font = @abi_font@
abi_videodrv = @abi_videodrv@
abi_xinput = @abi_xinput@
abs_builddir = @abs_builddir@
@@ -327,6 +335,7 @@ build_vendor = @build_vendor@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
+distcleancheck_listfiles = @distcleancheck_listfiles@
docdir = @docdir@
driverdir = @driverdir@
dvidir = @dvidir@
@@ -358,7 +367,9 @@ psdir = @psdir@
sbindir = @sbindir@
sdkdir = @sdkdir@
sharedstatedir = @sharedstatedir@
+shavedir = @shavedir@
srcdir = @srcdir@
+symbol_visibility = @symbol_visibility@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
@@ -369,16 +380,12 @@ INCLUDES = \
@KDRIVE_CFLAGS@
AM_CFLAGS = -DHAVE_DIX_CONFIG_H
-noinst_LIBRARIES = libkdrive.a libkdrivestubs.a
-@KDRIVE_HW_TRUE@KDRIVE_HW_SOURCES = \
-@KDRIVE_HW_TRUE@ vga.c \
-@KDRIVE_HW_TRUE@ vga.h
-
+noinst_LTLIBRARIES = libkdrive.la libkdrivestubs.la
@XV_TRUE@KDRIVE_XV_SOURCES = \
@XV_TRUE@ kxv.c \
@XV_TRUE@ kxv.h
-libkdrive_a_SOURCES = \
+libkdrive_la_SOURCES = \
fourcc.h \
kcmap.c \
kcurscol.c \
@@ -386,15 +393,13 @@ libkdrive_a_SOURCES = \
kdrive.h \
kinfo.c \
kinput.c \
- kkeymap.c \
kmap.c \
kmode.c \
kshadow.c \
$(KDRIVE_XV_SOURCES) \
- $(KDRIVE_HW_SOURCES) \
$(top_srcdir)/mi/miinitext.c
-libkdrivestubs_a_SOURCES = \
+libkdrivestubs_la_SOURCES = \
$(top_srcdir)/fb/fbcmap_mi.c
all: all-am
@@ -432,16 +437,18 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
-clean-noinstLIBRARIES:
- -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES)
-libkdrive.a: $(libkdrive_a_OBJECTS) $(libkdrive_a_DEPENDENCIES)
- -rm -f libkdrive.a
- $(libkdrive_a_AR) libkdrive.a $(libkdrive_a_OBJECTS) $(libkdrive_a_LIBADD)
- $(RANLIB) libkdrive.a
-libkdrivestubs.a: $(libkdrivestubs_a_OBJECTS) $(libkdrivestubs_a_DEPENDENCIES)
- -rm -f libkdrivestubs.a
- $(libkdrivestubs_a_AR) libkdrivestubs.a $(libkdrivestubs_a_OBJECTS) $(libkdrivestubs_a_LIBADD)
- $(RANLIB) libkdrivestubs.a
+clean-noinstLTLIBRARIES:
+ -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
+ @list='$(noinst_LTLIBRARIES)'; for p in $$list; do \
+ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
+ test "$$dir" != "$$p" || dir=.; \
+ echo "rm -f \"$${dir}/so_locations\""; \
+ rm -f "$${dir}/so_locations"; \
+ done
+libkdrive.la: $(libkdrive_la_OBJECTS) $(libkdrive_la_DEPENDENCIES)
+ $(LINK) $(libkdrive_la_OBJECTS) $(libkdrive_la_LIBADD) $(LIBS)
+libkdrivestubs.la: $(libkdrivestubs_la_OBJECTS) $(libkdrivestubs_la_DEPENDENCIES)
+ $(LINK) $(libkdrivestubs_la_OBJECTS) $(libkdrivestubs_la_LIBADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
@@ -449,19 +456,17 @@ mostlyclean-compile:
distclean-compile:
-rm -f *.tab.c
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fbcmap_mi.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kcmap.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kcurscol.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kdrive.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kinfo.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kinput.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kkeymap.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kmap.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kmode.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kshadow.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kxv.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/miinitext.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vga.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fbcmap_mi.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kcmap.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kcurscol.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kdrive.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kinfo.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kinput.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kmap.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kmode.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kshadow.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kxv.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/miinitext.Plo@am__quote@
.c.o:
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@@ -484,33 +489,19 @@ distclean-compile:
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $<
-miinitext.o: $(top_srcdir)/mi/miinitext.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT miinitext.o -MD -MP -MF $(DEPDIR)/miinitext.Tpo -c -o miinitext.o `test -f '$(top_srcdir)/mi/miinitext.c' || echo '$(srcdir)/'`$(top_srcdir)/mi/miinitext.c
-@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/miinitext.Tpo $(DEPDIR)/miinitext.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/mi/miinitext.c' object='miinitext.o' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o miinitext.o `test -f '$(top_srcdir)/mi/miinitext.c' || echo '$(srcdir)/'`$(top_srcdir)/mi/miinitext.c
-
-miinitext.obj: $(top_srcdir)/mi/miinitext.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT miinitext.obj -MD -MP -MF $(DEPDIR)/miinitext.Tpo -c -o miinitext.obj `if test -f '$(top_srcdir)/mi/miinitext.c'; then $(CYGPATH_W) '$(top_srcdir)/mi/miinitext.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mi/miinitext.c'; fi`
-@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/miinitext.Tpo $(DEPDIR)/miinitext.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/mi/miinitext.c' object='miinitext.obj' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o miinitext.obj `if test -f '$(top_srcdir)/mi/miinitext.c'; then $(CYGPATH_W) '$(top_srcdir)/mi/miinitext.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mi/miinitext.c'; fi`
-
-fbcmap_mi.o: $(top_srcdir)/fb/fbcmap_mi.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT fbcmap_mi.o -MD -MP -MF $(DEPDIR)/fbcmap_mi.Tpo -c -o fbcmap_mi.o `test -f '$(top_srcdir)/fb/fbcmap_mi.c' || echo '$(srcdir)/'`$(top_srcdir)/fb/fbcmap_mi.c
-@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/fbcmap_mi.Tpo $(DEPDIR)/fbcmap_mi.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/fb/fbcmap_mi.c' object='fbcmap_mi.o' libtool=no @AMDEPBACKSLASH@
+miinitext.lo: $(top_srcdir)/mi/miinitext.c
+@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT miinitext.lo -MD -MP -MF $(DEPDIR)/miinitext.Tpo -c -o miinitext.lo `test -f '$(top_srcdir)/mi/miinitext.c' || echo '$(srcdir)/'`$(top_srcdir)/mi/miinitext.c
+@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/miinitext.Tpo $(DEPDIR)/miinitext.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/mi/miinitext.c' object='miinitext.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o fbcmap_mi.o `test -f '$(top_srcdir)/fb/fbcmap_mi.c' || echo '$(srcdir)/'`$(top_srcdir)/fb/fbcmap_mi.c
+@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o miinitext.lo `test -f '$(top_srcdir)/mi/miinitext.c' || echo '$(srcdir)/'`$(top_srcdir)/mi/miinitext.c
-fbcmap_mi.obj: $(top_srcdir)/fb/fbcmap_mi.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT fbcmap_mi.obj -MD -MP -MF $(DEPDIR)/fbcmap_mi.Tpo -c -o fbcmap_mi.obj `if test -f '$(top_srcdir)/fb/fbcmap_mi.c'; then $(CYGPATH_W) '$(top_srcdir)/fb/fbcmap_mi.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/fb/fbcmap_mi.c'; fi`
-@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/fbcmap_mi.Tpo $(DEPDIR)/fbcmap_mi.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/fb/fbcmap_mi.c' object='fbcmap_mi.obj' libtool=no @AMDEPBACKSLASH@
+fbcmap_mi.lo: $(top_srcdir)/fb/fbcmap_mi.c
+@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT fbcmap_mi.lo -MD -MP -MF $(DEPDIR)/fbcmap_mi.Tpo -c -o fbcmap_mi.lo `test -f '$(top_srcdir)/fb/fbcmap_mi.c' || echo '$(srcdir)/'`$(top_srcdir)/fb/fbcmap_mi.c
+@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/fbcmap_mi.Tpo $(DEPDIR)/fbcmap_mi.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/fb/fbcmap_mi.c' object='fbcmap_mi.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o fbcmap_mi.obj `if test -f '$(top_srcdir)/fb/fbcmap_mi.c'; then $(CYGPATH_W) '$(top_srcdir)/fb/fbcmap_mi.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/fb/fbcmap_mi.c'; fi`
+@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o fbcmap_mi.lo `test -f '$(top_srcdir)/fb/fbcmap_mi.c' || echo '$(srcdir)/'`$(top_srcdir)/fb/fbcmap_mi.c
mostlyclean-libtool:
-rm -f *.lo
@@ -602,7 +593,7 @@ distdir: $(DISTFILES)
done
check-am: all-am
check: check-am
-all-am: Makefile $(LIBRARIES)
+all-am: Makefile $(LTLIBRARIES)
installdirs:
install: install-am
install-exec: install-exec-am
@@ -631,7 +622,7 @@ maintainer-clean-generic:
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
-clean-am: clean-generic clean-libtool clean-noinstLIBRARIES \
+clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \
mostlyclean-am
distclean: distclean-am
@@ -703,7 +694,7 @@ uninstall-am:
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
- clean-libtool clean-noinstLIBRARIES ctags distclean \
+ clean-libtool clean-noinstLTLIBRARIES ctags distclean \
distclean-compile distclean-generic distclean-libtool \
distclean-tags distdir dvi dvi-am html html-am info info-am \
install install-am install-data install-data-am install-dvi \
diff --git a/xorg-server/hw/kdrive/src/kcmap.c b/xorg-server/hw/kdrive/src/kcmap.c
index 4941ad17f..2c33e798a 100644
--- a/xorg-server/hw/kdrive/src/kcmap.c
+++ b/xorg-server/hw/kdrive/src/kcmap.c
@@ -217,7 +217,8 @@ KdUninstallColormap (ColormapPtr pCmap)
return;
/* install default if on same fb */
- defMap = (ColormapPtr) LookupIDByType(defMapID, RT_COLORMAP);
+ dixLookupResourceByType((pointer *)&defMap, defMapID, RT_COLORMAP,
+ serverClient, DixInstallAccess);
if (defMap && KdColormapFb (defMap) == fb)
(*pCmap->pScreen->InstallColormap)(defMap);
else
diff --git a/xorg-server/hw/kdrive/src/kdrive.c b/xorg-server/hw/kdrive/src/kdrive.c
index 97d167e1e..5cfe54ff8 100644
--- a/xorg-server/hw/kdrive/src/kdrive.c
+++ b/xorg-server/hw/kdrive/src/kdrive.c
@@ -24,9 +24,6 @@
#include <kdrive-config.h>
#endif
#include "kdrive.h"
-#ifdef PSEUDO8
-#include "pseudo8/pseudo8.h"
-#endif
#include <mivalidate.h>
#include <dixstruct.h>
#include "privates.h"
@@ -102,7 +99,6 @@ KdSetRootClip (ScreenPtr pScreen, BOOL enable)
WindowPtr pChild;
Bool WasViewable;
Bool anyMarked = FALSE;
- RegionPtr pOldClip = 0;
WindowPtr pLayerWin;
BoxRec box;
@@ -343,7 +339,7 @@ AbortDDX(void)
}
void
-ddxGiveUp ()
+ddxGiveUp (void)
{
AbortDDX ();
}
@@ -521,17 +517,6 @@ KdParseScreen (KdScreenInfo *screen,
* {NMO} Reorder buttons
*/
-char *
-KdSaveString (char *str)
-{
- char *n = (char *) xalloc (strlen (str) + 1);
-
- if (!n)
- return 0;
- strcpy (n, str);
- return n;
-}
-
void
KdParseRgba (char *rgba)
{
@@ -553,7 +538,6 @@ void
KdUseMsg (void)
{
ErrorF("\nTinyX Device Dependent Usage:\n");
- ErrorF("-card pcmcia Use PCMCIA card as additional screen\n");
ErrorF("-screen WIDTH[/WIDTHMM]xHEIGHT[/HEIGHTMM][@ROTATION][X][Y][xDEPTH/BPP{,DEPTH/BPP}[xFREQ]] Specify screen characteristics\n");
ErrorF("-rgba rgb/bgr/vrgb/vbgr/none Specify subpixel ordering for LCD panels\n");
ErrorF("-mouse driver [,n,,options] Specify the pointer driver and its options (n is the number of buttons)\n");
@@ -569,9 +553,6 @@ KdUseMsg (void)
ErrorF("-switchCmd Command to execute on vt switch\n");
ErrorF("-zap Terminate server on Ctrl+Alt+Backspace\n");
ErrorF("vtxx Use virtual terminal xx instead of the next available\n");
-#ifdef PSEUDO8
- p8UseMsg ();
-#endif
}
int
@@ -580,14 +561,6 @@ KdProcessArgument (int argc, char **argv, int i)
KdCardInfo *card;
KdScreenInfo *screen;
- if (!strcmp (argv[i], "-card"))
- {
- if ((i+1) < argc)
- InitCard (argv[i+1]);
- else
- UseMsg ();
- return 2;
- }
if (!strcmp (argv[i], "-screen"))
{
if ((i+1) < argc)
@@ -704,11 +677,7 @@ KdProcessArgument (int argc, char **argv, int i)
return 2;
}
-#ifdef PSEUDO8
- return p8ProcessArgument (argc, argv, i);
-#else
return 0;
-#endif
}
/*
@@ -1079,10 +1048,6 @@ KdScreenInit(int index, ScreenPtr pScreen, int argc, char **argv)
if (!(*card->cfuncs->initAccel) (pScreen))
screen->dumb = TRUE;
-#ifdef PSEUDO8
- (void) p8Init (pScreen, PSEUDO8_USE_DEFAULT);
-#endif
-
if (card->cfuncs->finishInitScreen)
if (!(*card->cfuncs->finishInitScreen) (pScreen))
return FALSE;
@@ -1290,38 +1255,12 @@ KdDepthToFb (ScreenPtr pScreen, int depth)
#endif
-#ifdef HAVE_BACKTRACE
-/* shamelessly ripped from xf86Events.c */
-void
-KdBacktrace (int signum)
-{
- void *array[32]; /* more than 32 and you have bigger problems */
- size_t size, i;
- char **strings;
-
- signal(signum, SIG_IGN);
-
- size = backtrace (array, 32);
- fprintf (stderr, "\nBacktrace (%d deep):\n", size);
- strings = backtrace_symbols (array, size);
- for (i = 0; i < size; i++)
- fprintf (stderr, "%d: %s\n", i, strings[i]);
- free (strings);
-
- kdCaughtSignal = TRUE;
- if (signum == SIGSEGV)
- FatalError("Segmentation fault caught\n");
- else if (signum > 0)
- FatalError("Signal %d caught\n", signum);
-}
-#else
-void
-KdBacktrace (int signum)
+static int
+KdSignalWrapper (int signum)
{
kdCaughtSignal = TRUE;
- FatalError("Segmentation fault caught\n");
+ return 1; /* use generic OS layer cleanup & abort */
}
-#endif
void
KdInitOutput (ScreenInfo *pScreenInfo,
@@ -1368,7 +1307,7 @@ KdInitOutput (ScreenInfo *pScreenInfo,
for (screen = card->screenList; screen; screen = screen->next)
KdAddScreen (pScreenInfo, screen, argc, argv);
- signal(SIGSEGV, KdBacktrace);
+ OsRegisterSigWrapper(KdSignalWrapper);
}
void
@@ -1376,16 +1315,10 @@ OsVendorFatalError(void)
{
}
-#ifdef DPMSExtension
int
DPMSSet(ClientPtr client, int level)
{
-}
-
-int
-DPMSGet (int *level)
-{
- return -1;
+ return Success;
}
Bool
@@ -1393,5 +1326,3 @@ DPMSSupported (void)
{
return FALSE;
}
-#endif
-
diff --git a/xorg-server/hw/kdrive/src/kdrive.h b/xorg-server/hw/kdrive/src/kdrive.h
index 8e1998ef9..6fdb7087f 100644
--- a/xorg-server/hw/kdrive/src/kdrive.h
+++ b/xorg-server/hw/kdrive/src/kdrive.h
@@ -24,8 +24,8 @@
#define _KDRIVE_H_
#include <stdio.h>
+#include <string.h>
#include <X11/X.h>
-#define NEED_EVENTS
#include <X11/Xproto.h>
#include <X11/Xos.h>
#include "scrnintstr.h"
@@ -45,9 +45,7 @@
#include "randrstr.h"
#include "globals.h"
-#ifdef XKB
-#include <X11/extensions/XKBstr.h>
-#endif
+#include "xkbstr.h"
#define KD_DPMS_NORMAL 0
#define KD_DPMS_STANDBY 1
@@ -222,6 +220,7 @@ struct _KdPointerInfo {
DeviceIntPtr dixdev;
char *name;
char *path;
+ char *protocol;
InputOption *options;
int inputClass;
@@ -276,11 +275,6 @@ typedef struct {
int modbit;
} KdKeySymModsRec;
-extern const KeySym kdDefaultKeymap[KD_MAX_LENGTH * KD_MAX_WIDTH];
-extern const int kdDefaultKeymapWidth;
-extern const CARD8 kdDefaultModMap[MAP_LENGTH];
-extern const KeySymsRec kdDefaultKeySyms;
-
typedef struct _KdKeyboardInfo KdKeyboardInfo;
typedef struct _KdKeyboardDriver {
@@ -301,21 +295,16 @@ struct _KdKeyboardInfo {
char *name;
char *path;
int inputClass;
-#ifdef XKB
XkbDescPtr xkb;
char *xkbRules;
char *xkbModel;
char *xkbLayout;
char *xkbVariant;
char *xkbOptions;
-#endif
int LockLed;
- CARD8 keyState[KD_KEY_COUNT/8];
int minScanCode;
int maxScanCode;
- CARD8 modmap[MAP_LENGTH];
- KeySymsRec keySyms;
int leds;
int bellPitch;
@@ -474,9 +463,6 @@ void
KdParseScreen (KdScreenInfo *screen,
char *arg);
-char *
-KdSaveString (char *str);
-
KdPointerInfo *
KdParsePointer (char *arg);
diff --git a/xorg-server/hw/kdrive/src/kinfo.c b/xorg-server/hw/kdrive/src/kinfo.c
index d592e6803..cb646130e 100644
--- a/xorg-server/hw/kdrive/src/kinfo.c
+++ b/xorg-server/hw/kdrive/src/kinfo.c
@@ -118,7 +118,7 @@ KdNewPointer (void)
if (!pi)
return NULL;
- pi->name = KdSaveString("Generic Pointer");
+ pi->name = strdup("Generic Pointer");
pi->path = NULL;
pi->inputClass = KD_MOUSE;
pi->driver = NULL;
diff --git a/xorg-server/hw/kdrive/src/kinput.c b/xorg-server/hw/kdrive/src/kinput.c
index 8e6a475d1..318d233d4 100644
--- a/xorg-server/hw/kdrive/src/kinput.c
+++ b/xorg-server/hw/kdrive/src/kinput.c
@@ -38,9 +38,7 @@
#include <sys/file.h> /* needed for FNONBLOCK & FASYNC */
#endif
-#ifdef XKB
-#include <xkbsrv.h>
-#endif
+#include "xkbsrv.h"
#include <X11/extensions/XI.h>
#include <X11/extensions/XIproto.h>
@@ -48,6 +46,8 @@
#include "exevents.h"
#include "extinit.h"
#include "exglobals.h"
+#include "eventstr.h"
+#include "xserver-properties.h"
#define AtomFromName(x) MakeAtom(x, strlen(x), 1)
@@ -77,12 +77,6 @@ static KdPointerMatrix kdPointerMatrix = {
void KdResetInputMachine (void);
-#define IsKeyDown(ki, key) ((ki->keyState[(key) >> 3] >> ((key) & 7)) & 1)
-#define KEYMAP(ki) (ki->dixdev->key->curKeySyms)
-#define KEYMAPDDX(ki) (ki->keySyms)
-#define KEYCOL1(ki, k) (KEYMAP(ki).map[((k)-(KEYMAP(ki).minKeyCode))*KEYMAP(ki).mapWidth])
-#define KEYCOL1DDX(ki, k) (KEYMAPDDX(ki).map[((k)-(KEYMAPDDX(ki).minKeyCode))*KEYMAPDDX(ki).mapWidth])
-
#define KD_MAX_INPUT_FDS 8
typedef struct _kdInputFd {
@@ -327,7 +321,7 @@ KdDisableInput (void)
void
KdEnableInput (void)
{
- xEvent xE;
+ InternalEvent ev;
KdKeyboardInfo *ki;
KdPointerInfo *pi;
@@ -344,8 +338,8 @@ KdEnableInput (void)
}
/* reset screen saver */
- xE.u.keyButtonPointer.time = GetTimeInMillis ();
- NoticeEventTime (&xE);
+ ev.any.time = GetTimeInMillis ();
+ NoticeEventTime (&ev);
KdUnblockSigio ();
}
@@ -390,6 +384,8 @@ KdPointerProc(DeviceIntPtr pDevice, int onoff)
DevicePtr pDev = (DevicePtr)pDevice;
KdPointerInfo *pi;
Atom xiclass;
+ Atom *btn_labels;
+ Atom *axes_labels;
if (!pDev)
return BadImplementation;
@@ -437,9 +433,47 @@ KdPointerProc(DeviceIntPtr pDevice, int onoff)
return !Success;
}
- InitPointerDeviceStruct(pDev, pi->map, pi->nButtons,
+ btn_labels = xcalloc(pi->nButtons, sizeof(Atom));
+ if (!btn_labels)
+ return BadAlloc;
+ axes_labels = xcalloc(pi->nAxes, sizeof(Atom));
+ if (!axes_labels) {
+ xfree(btn_labels);
+ return BadAlloc;
+ }
+
+ switch(pi->nAxes)
+ {
+ default:
+ case 7:
+ btn_labels[6] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_HWHEEL_RIGHT);
+ case 6:
+ btn_labels[5] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_HWHEEL_LEFT);
+ case 5:
+ btn_labels[4] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_WHEEL_DOWN);
+ case 4:
+ btn_labels[3] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_WHEEL_UP);
+ case 3:
+ btn_labels[2] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_RIGHT);
+ case 2:
+ btn_labels[1] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_MIDDLE);
+ case 1:
+ btn_labels[0] = XIGetKnownProperty(BTN_LABEL_PROP_BTN_LEFT);
+ case 0:
+ break;
+ }
+
+ if (pi->nAxes >= 2) {
+ axes_labels[0] = XIGetKnownProperty(AXIS_LABEL_PROP_REL_X);
+ axes_labels[1] = XIGetKnownProperty(AXIS_LABEL_PROP_REL_Y);
+ }
+
+ InitPointerDeviceStruct(pDev, pi->map, pi->nButtons, btn_labels,
(PtrCtrlProcPtr)NoopDDA,
- GetMotionHistorySize(), pi->nAxes);
+ GetMotionHistorySize(), pi->nAxes, axes_labels);
+
+ xfree(btn_labels);
+ xfree(axes_labels);
if (pi->inputClass == KD_TOUCHSCREEN) {
InitAbsoluteClassDeviceStruct(pDevice);
@@ -662,85 +696,6 @@ KdKbdCtrl (DeviceIntPtr pDevice, KeybdCtrl *ctrl)
extern KeybdCtrl defaultKeyboardControl;
-static void
-KdInitAutoRepeats (KdKeyboardInfo *ki)
-{
- int key_code;
- unsigned char mask;
- int i;
- unsigned char *repeats;
-
- repeats = defaultKeyboardControl.autoRepeats;
- memset (repeats, '\0', 32);
- for (key_code = KD_MIN_KEYCODE; key_code <= KD_MAX_KEYCODE; key_code++)
- {
- if (!ki->modmap[key_code])
- {
- i = key_code >> 3;
- mask = 1 << (key_code & 7);
- repeats[i] |= mask;
- }
- }
-}
-
-const KdKeySymModsRec kdKeySymMods[] = {
- { XK_Control_L, ControlMask },
- { XK_Control_R, ControlMask },
- { XK_Shift_L, ShiftMask },
- { XK_Shift_R, ShiftMask },
- { XK_Caps_Lock, LockMask },
- { XK_Shift_Lock, LockMask },
- { XK_Alt_L, Mod1Mask },
- { XK_Alt_R, Mod1Mask },
- { XK_Meta_L, Mod1Mask },
- { XK_Meta_R, Mod1Mask },
- { XK_Num_Lock, Mod2Mask },
- { XK_Super_L, Mod3Mask },
- { XK_Super_R, Mod3Mask },
- { XK_Hyper_L, Mod3Mask },
- { XK_Hyper_R, Mod3Mask },
- { XK_Mode_switch, Mod4Mask },
- /* PDA specific hacks */
-#ifdef XF86XK_Start
- { XF86XK_Start, ControlMask },
-#endif
- { XK_Menu, ShiftMask },
- { XK_telephone, Mod1Mask },
-#ifdef XF86XK_AudioRecord
- { XF86XK_AudioRecord, Mod2Mask },
-#endif
-#ifdef XF86XK_Calendar
- { XF86XK_Calendar, Mod3Mask }
-#endif
-};
-
-#define NUM_SYM_MODS (sizeof(kdKeySymMods) / sizeof(kdKeySymMods[0]))
-
-static void
-KdInitModMap (KdKeyboardInfo *ki)
-{
- int key_code;
- int row;
- int width;
- KeySym *syms;
- int i;
-
- width = ki->keySyms.mapWidth;
- for (key_code = ki->keySyms.minKeyCode; key_code <= ki->keySyms.maxKeyCode; key_code++)
- {
- ki->modmap[key_code] = 0;
- syms = ki->keySyms.map + (key_code - ki->keySyms.minKeyCode) * width;
- for (row = 0; row < width; row++, syms++)
- {
- for (i = 0; i < NUM_SYM_MODS; i++)
- {
- if (*syms == kdKeySymMods[i].modsym)
- ki->modmap[key_code] |= kdKeySymMods[i].modbit;
- }
- }
- }
-}
-
static int
KdKeyboardProc(DeviceIntPtr pDevice, int onoff)
{
@@ -748,9 +703,7 @@ KdKeyboardProc(DeviceIntPtr pDevice, int onoff)
DevicePtr pDev = (DevicePtr)pDevice;
KdKeyboardInfo *ki;
Atom xiclass;
-#ifdef XKB
- XkbComponentNamesRec names;
-#endif
+ XkbRMLVOSet rmlvo;
if (!pDev)
return BadImplementation;
@@ -796,28 +749,13 @@ KdKeyboardProc(DeviceIntPtr pDevice, int onoff)
return !Success;
}
- KdInitModMap(ki);
- KdInitAutoRepeats(ki);
-
-#ifdef XKB
- if (!noXkbExtension) {
- memset(&names, 0, sizeof(XkbComponentNamesRec));
-
- XkbSetRulesDflts (ki->xkbRules, ki->xkbModel, ki->xkbLayout,
- ki->xkbVariant, ki->xkbOptions);
-
- ret = XkbInitKeyboardDeviceStruct (pDevice,
- &names,
- &ki->keySyms,
- ki->modmap,
- KdBell, KdKbdCtrl);
- }
- else
-#endif
- ret = InitKeyboardDeviceStruct(pDev,
- &ki->keySyms,
- ki->modmap,
- KdBell, KdKbdCtrl);
+ memset(&rmlvo, 0, sizeof(rmlvo));
+ rmlvo.rules = ki->xkbRules;
+ rmlvo.model = ki->xkbModel;
+ rmlvo.layout = ki->xkbLayout;
+ rmlvo.variant = ki->xkbVariant;
+ rmlvo.options = ki->xkbOptions;
+ ret = InitKeyboardDeviceStruct (pDevice, &rmlvo, KdBell, KdKbdCtrl);
if (!ret) {
ErrorF("Couldn't initialise keyboard %s\n", ki->name);
return BadImplementation;
@@ -950,23 +888,9 @@ KdKeyboardInfo *
KdNewKeyboard (void)
{
KdKeyboardInfo *ki = xcalloc(sizeof(KdKeyboardInfo), 1);
-
if (!ki)
return NULL;
-
- ki->keySyms.map = (KeySym *)xcalloc(sizeof(KeySym),
- KD_MAX_LENGTH *
- kdDefaultKeySyms.mapWidth);
- if (!ki->keySyms.map) {
- xfree(ki);
- return NULL;
- }
- memcpy(ki->keySyms.map, kdDefaultKeySyms.map,
- sizeof(KeySym) * (KD_MAX_LENGTH * kdDefaultKeySyms.mapWidth));
- ki->keySyms.minKeyCode = kdDefaultKeySyms.minKeyCode;
- ki->keySyms.maxKeyCode = kdDefaultKeySyms.maxKeyCode;
- ki->keySyms.mapWidth = kdDefaultKeySyms.mapWidth;
ki->minScanCode = 0;
ki->maxScanCode = 0;
ki->leds = 0;
@@ -974,13 +898,11 @@ KdNewKeyboard (void)
ki->bellDuration = 200;
ki->next = NULL;
ki->options = NULL;
-#ifdef XKB
- ki->xkbRules = KdSaveString("base");
- ki->xkbModel = KdSaveString("pc105");
- ki->xkbLayout = KdSaveString("us");
+ ki->xkbRules = strdup("base");
+ ki->xkbModel = strdup("pc105");
+ ki->xkbLayout = strdup("us");
ki->xkbVariant = NULL;
ki->xkbOptions = NULL;
-#endif
return ki;
}
@@ -1164,7 +1086,6 @@ KdParseKbdOptions (KdKeyboardInfo *ki)
for (option = ki->options; option; option = option->next)
{
-#ifdef XKB
if (strcasecmp(option->key, "XkbRules") == 0)
ki->xkbRules = option->value;
else if (strcasecmp(option->key, "XkbModel") == 0)
@@ -1176,9 +1097,8 @@ KdParseKbdOptions (KdKeyboardInfo *ki)
else if (strcasecmp(option->key, "XkbOptions") == 0)
ki->xkbOptions = option->value;
else if (!strcasecmp (option->key, "device"))
- ki->path = KdSaveString(option->value);
+ ki->path = strdup(option->value);
else
-#endif
ErrorF("Kbd option key (%s) of value (%s) not assigned!\n",
option->key, option->value);
}
@@ -1200,9 +1120,7 @@ KdParseKeyboard (char *arg)
ki->path = NULL;
ki->driver = NULL;
ki->driverPrivate = NULL;
-#ifdef XKB
ki->xkb = NULL;
-#endif
ki->next = NULL;
if (!arg)
@@ -1275,7 +1193,9 @@ KdParsePointerOptions (KdPointerInfo *pi)
else if (!strcmp (option->key, "rawcoord"))
pi->transformCoordinates = FALSE;
else if (!strcasecmp (option->key, "device"))
- pi->path = KdSaveString(option->value);
+ pi->path = strdup(option->value);
+ else if (!strcasecmp (option->key, "protocol"))
+ pi->protocol = strdup(option->value);
else
ErrorF("Pointer option key (%s) of value (%s) not assigned!\n",
option->key, option->value);
@@ -1296,6 +1216,7 @@ KdParsePointer (char *arg)
return NULL;
pi->emulateMiddleButton = kdEmulateMiddleButton;
pi->transformCoordinates = !kdRawPointerCoordinates;
+ pi->protocol = NULL;
pi->nButtons = 5; /* XXX should not be hardcoded */
pi->inputClass = KD_MOUSE;
@@ -1776,7 +1697,7 @@ char *kdActionNames[] = {
#endif /* DEBUG */
static void
-KdQueueEvent (DeviceIntPtr pDev, xEvent *ev)
+KdQueueEvent (DeviceIntPtr pDev, InternalEvent *ev)
{
KdAssertSigioBlocked ("KdQueueEvent");
mieqEnqueue (pDev, ev);
@@ -1864,13 +1785,6 @@ KdReceiveTimeout (KdPointerInfo *pi)
KdRunMouseMachine (pi, timeout, 0, 0, 0, 0, 0, 0);
}
-#define KILL_SEQUENCE ((1L << KK_CONTROL)|(1L << KK_ALT)|(1L << KK_F8)|(1L << KK_F10))
-#define SPECIAL_SEQUENCE ((1L << KK_CONTROL) | (1L << KK_ALT))
-#define SETKILLKEY(b) (KdSpecialKeys |= (1L << (b)))
-#define CLEARKILLKEY(b) (KdSpecialKeys &= ~(1L << (b)))
-
-CARD32 KdSpecialKeys = 0;
-
/*
* kdCheckTermination
*
@@ -1884,92 +1798,10 @@ CARD32 KdSpecialKeys = 0;
extern int nClients;
-static void
-KdCheckSpecialKeys(KdKeyboardInfo *ki, int type, int sym)
-{
- if (!ki)
- return;
-
- /*
- * Ignore key releases
- */
-
- if (type == KeyRelease)
- return;
-
- /* Some iPaq keyboard -> mouse button mapping used to be here, but I
- * refuse to perpetuate this madness. -daniels */
-
- /*
- * Check for control/alt pressed
- */
- if ((ki->dixdev->key->state & (ControlMask|Mod1Mask)) !=
- (ControlMask|Mod1Mask))
- return;
-
- /*
- * Let OS function see keysym first
- */
-
- if (kdOsFuncs->SpecialKey)
- if ((*kdOsFuncs->SpecialKey) (sym))
- return;
-
- /*
- * Now check for backspace or delete; these signal the
- * X server to terminate
- *
- * I can't believe it's not XKB. -daniels
- */
- switch (sym) {
- case XK_BackSpace:
- case XK_Delete:
- case XK_KP_Delete:
- /*
- * Set the dispatch exception flag so the server will terminate the
- * next time through the dispatch loop.
- */
- if (kdAllowZap || party_like_its_1989)
- dispatchException |= DE_TERMINATE;
- break;
- }
-}
-
-/*
- * kdEnqueueKeyboardEvent
- *
- * This function converts hardware keyboard event information into an X event
- * and enqueues it using MI. It wakes up the server before returning so that
- * the event will be processed normally.
- *
- */
-
-static void
-KdHandleKeyboardEvent (KdKeyboardInfo *ki, int type, int key)
-{
- int byte;
- CARD8 bit;
- KdPointerInfo *pi;
-
- byte = key >> 3;
- bit = 1 << (key & 7);
-
- switch (type) {
- case KeyPress:
- ki->keyState[byte] |= bit;
- break;
- case KeyRelease:
- ki->keyState[byte] &= ~bit;
- break;
- }
-
- for (pi = kdPointers; pi; pi = pi->next)
- KdRunMouseMachine (pi, keyboard, 0, 0, 0, 0, 0, 0);
-}
-
void
KdReleaseAllKeys (void)
{
+#if 0
int key, nEvents, i;
KdKeyboardInfo *ki;
@@ -1978,7 +1810,7 @@ KdReleaseAllKeys (void)
for (ki = kdKeyboards; ki; ki = ki->next) {
for (key = ki->keySyms.minKeyCode; key < ki->keySyms.maxKeyCode;
key++) {
- if (IsKeyDown(ki, key)) {
+ if (key_is_down(ki->dixdev, key, KEY_POSTED | KEY_PROCESSED)) {
KdHandleKeyboardEvent(ki, KeyRelease, key);
GetEventList(&kdEvents);
nEvents = GetKeyboardEvents(kdEvents, ki->dixdev, KeyRelease, key);
@@ -1989,6 +1821,7 @@ KdReleaseAllKeys (void)
}
KdUnblockSigio ();
+#endif
}
static void
@@ -2002,7 +1835,8 @@ KdCheckLock (void)
if (tmp->LockLed && tmp->dixdev && tmp->dixdev->key) {
keyc = tmp->dixdev->key;
isSet = (tmp->leds & (1 << (tmp->LockLed-1))) != 0;
- shouldBeSet = (keyc->state & LockMask) != 0;
+ /* FIXME: Just use XKB indicators! */
+ shouldBeSet = !!(XkbStateFieldFromRec(&keyc->xkbInfo->state) & LockMask);
if (isSet != shouldBeSet)
KdSetLed (tmp, tmp->LockLed, shouldBeSet);
}
@@ -2028,7 +1862,7 @@ KdEnqueueKeyboardEvent(KdKeyboardInfo *ki,
if (scan_code >= ki->minScanCode && scan_code <= ki->maxScanCode)
{
key_code = scan_code + KD_MIN_KEYCODE - ki->minScanCode;
-
+
/*
* Set up this event -- the type may be modified below
*/
@@ -2036,19 +1870,12 @@ KdEnqueueKeyboardEvent(KdKeyboardInfo *ki,
type = KeyRelease;
else
type = KeyPress;
-
-#ifdef XKB
- if (noXkbExtension)
-#endif
- {
- KdCheckSpecialKeys(ki, type, key_code);
- KdHandleKeyboardEvent(ki, type, key_code);
- }
-
+
GetEventList(&kdEvents);
+
nEvents = GetKeyboardEvents(kdEvents, ki->dixdev, type, key_code);
for (i = 0; i < nEvents; i++)
- KdQueueEvent(ki->dixdev, (kdEvents + i)->event);
+ KdQueueEvent(ki->dixdev, (InternalEvent *)((kdEvents + i)->event));
}
else {
ErrorF("driver %s wanted to post scancode %d outside of [%d, %d]!\n",
@@ -2096,8 +1923,8 @@ KdEnqueuePointerEvent(KdPointerInfo *pi, unsigned long flags, int rx, int ry,
}
else {
if (pi->transformCoordinates) {
- x = matrix[0][0] * rx + matrix[0][1] * ry;
- y = matrix[1][0] * rx + matrix[1][1] * ry;
+ x = matrix[0][0] * rx + matrix[0][1] * ry + matrix[0][2];
+ y = matrix[1][0] * rx + matrix[1][1] * ry + matrix[1][2];
}
else {
x = rx;
@@ -2158,7 +1985,7 @@ _KdEnqueuePointerEvent (KdPointerInfo *pi, int type, int x, int y, int z,
nEvents = GetPointerEvents(kdEvents, pi->dixdev, type, b, absrel,
0, 3, valuators);
for (i = 0; i < nEvents; i++)
- KdQueueEvent(pi->dixdev, (kdEvents + i)->event);
+ KdQueueEvent(pi->dixdev, (InternalEvent *)((kdEvents + i)->event));
}
void
@@ -2349,7 +2176,7 @@ miPointerScreenFuncRec kdPointerScreenFuncs =
};
void
-ProcessInputEvents ()
+ProcessInputEvents (void)
{
mieqProcessInputEvents();
miPointerUpdateSprite(inputInfo.pointer);
@@ -2458,9 +2285,9 @@ NewInputDeviceRequest(InputOption *options, DeviceIntPtr *pdev)
for (option = options; option; option = option->next) {
if (strcmp(option->key, "device") == 0) {
if (pi && option->value)
- pi->path = KdSaveString(option->value);
+ pi->path = strdup(option->value);
else if (ki && option->value)
- ki->path = KdSaveString(option->value);
+ ki->path = strdup(option->value);
}
else if (strcmp(option->key, "driver") == 0) {
if (pi) {
@@ -2486,16 +2313,16 @@ NewInputDeviceRequest(InputOption *options, DeviceIntPtr *pdev)
if (pi) {
if (KdAddPointer(pi) != Success ||
- ActivateDevice(pi->dixdev) != Success ||
- EnableDevice(pi->dixdev) != TRUE) {
+ ActivateDevice(pi->dixdev, TRUE) != Success ||
+ EnableDevice(pi->dixdev, TRUE) != TRUE) {
ErrorF("couldn't add or enable pointer\n");
return BadImplementation;
}
}
else if (ki) {
if (KdAddKeyboard(ki) != Success ||
- ActivateDevice(ki->dixdev) != Success ||
- EnableDevice(ki->dixdev) != TRUE) {
+ ActivateDevice(ki->dixdev, TRUE) != Success ||
+ EnableDevice(ki->dixdev, TRUE) != TRUE) {
ErrorF("couldn't add or enable keyboard\n");
return BadImplementation;
}
@@ -2513,5 +2340,5 @@ NewInputDeviceRequest(InputOption *options, DeviceIntPtr *pdev)
void
DeleteInputDeviceRequest(DeviceIntPtr pDev)
{
- RemoveDevice(pDev);
+ RemoveDevice(pDev, TRUE);
}