On Sun, Jan 10, 2010 at 07:45:54PM -0800, Ping wrote:
> Without getting into the driver, we don't get the right NumScreen for
> TwinView setup (it would always be one).  However, we could fix it by
> checking TwinView in wacomcpl-exec.
> 
> So, without updating wacomcpl-exec, this patch doesn't fulfil the
> backward compatibility promise for Nvidia's TwiView setup in wacomcpl.

If we can get around this issue by not requiring the NumScreens that'd be
the best solution. Not just for xf86-input-wacom but also for linuxwacom -
why check something that can be obtained through some other property too?

note that the patch was just a stopgap to get wacomcpl to even start, I'm
aware that it would only return multiple screens for zaphod mode.

Cheers,
  Peter

> On Sun, Jan 10, 2010 at 6:36 PM, Peter Hutterer
> <[email protected]> wrote:
> > This is for backwards-compatibility with wacomcpl only, it simply returns
> > the screen count as seen by X clients.
> >
> > Signed-off-by: Peter Hutterer <[email protected]>
> > ---
> > Temporary stopgap measure to make wacomcpl at least start.
> >
> >  tools/xsetwacom.c |   10 ++++++++--
> >  1 files changed, 8 insertions(+), 2 deletions(-)
> >
> > diff --git a/tools/xsetwacom.c b/tools/xsetwacom.c
> > index f7817b2..6e641d5 100644
> > --- a/tools/xsetwacom.c
> > +++ b/tools/xsetwacom.c
> > @@ -78,6 +78,7 @@ static void get_rotate(Display *dpy, XDevice *dev, 
> > param_t *param, int argc, cha
> >  static void set_twinview(Display *dpy, XDevice *dev, param_t *param, int 
> > argc, char **argv);
> >  static void get_twinview(Display *dpy, XDevice *dev, param_t *param, int 
> > argc, char **argv);
> >  static void set_xydefault(Display *dpy, XDevice *dev, param_t *param, int 
> > argc, char **argv);
> > +static void get_num_screens(Display *dpy, XDevice *dev, param_t *param, 
> > int argc, char **argv);
> >  static void get_all(Display *dpy, XDevice *dev, param_t *param, int argc, 
> > char **argv);
> >  static void get_param(Display *dpy, XDevice *dev, param_t *param, int 
> > argc, char **argv);
> >  static void not_implemented(Display *dpy, XDevice *dev, param_t *param, 
> > int argc, char **argv)
> > @@ -807,8 +808,8 @@ static param_t parameters[] =
> >        {
> >                .name = "NumScreen",
> >                .desc = "Returns number of screens configured for the 
> > desktop. ",
> > -               .set_func = not_implemented,
> > -               .get_func = not_implemented,
> > +               .get_func = get_num_screens,
> > +               .prop_flags = PROP_FLAG_READONLY
> >        },
> >        {
> >                .name = "XScaling",
> > @@ -1835,6 +1836,11 @@ static void get_button(Display *dpy, XDevice *dev, 
> > param_t *param, int argc,
> >        XFlush(dpy);
> >  }
> >
> > +static void get_num_screens(Display *dpy, XDevice *dev, param_t *param, 
> > int argc, char **argv)
> > +{
> > +       print_value(param, "%d", ScreenCount(dpy));
> > +}
> > +
> >  static void get_all(Display *dpy, XDevice *dev, param_t *param, int argc, 
> > char **argv)
> >  {
> >        param_t *p = parameters;
> > --
> > 1.6.6

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Linuxwacom-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel

Reply via email to