|
@@ -151,12 +151,14 @@ static void ucb1400_ts_evt_add(struct input_dev *idev, u16 pressure, u16 x, u16
|
|
input_report_abs(idev, ABS_X, x);
|
|
input_report_abs(idev, ABS_X, x);
|
|
input_report_abs(idev, ABS_Y, y);
|
|
input_report_abs(idev, ABS_Y, y);
|
|
input_report_abs(idev, ABS_PRESSURE, pressure);
|
|
input_report_abs(idev, ABS_PRESSURE, pressure);
|
|
|
|
+ input_report_key(idev, BTN_TOUCH, 1);
|
|
input_sync(idev);
|
|
input_sync(idev);
|
|
}
|
|
}
|
|
|
|
|
|
static void ucb1400_ts_event_release(struct input_dev *idev)
|
|
static void ucb1400_ts_event_release(struct input_dev *idev)
|
|
{
|
|
{
|
|
input_report_abs(idev, ABS_PRESSURE, 0);
|
|
input_report_abs(idev, ABS_PRESSURE, 0);
|
|
|
|
+ input_report_key(idev, BTN_TOUCH, 0);
|
|
input_sync(idev);
|
|
input_sync(idev);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -377,7 +379,8 @@ static int ucb1400_ts_probe(struct platform_device *dev)
|
|
ucb->ts_idev->id.product = ucb->id;
|
|
ucb->ts_idev->id.product = ucb->id;
|
|
ucb->ts_idev->open = ucb1400_ts_open;
|
|
ucb->ts_idev->open = ucb1400_ts_open;
|
|
ucb->ts_idev->close = ucb1400_ts_close;
|
|
ucb->ts_idev->close = ucb1400_ts_close;
|
|
- ucb->ts_idev->evbit[0] = BIT_MASK(EV_ABS);
|
|
|
|
|
|
+ ucb->ts_idev->evbit[0] = BIT_MASK(EV_ABS) | BIT_MASK(EV_KEY);
|
|
|
|
+ ucb->ts_idev->keybit[BIT_WORD(BTN_TOUCH)] = BIT_MASK(BTN_TOUCH);
|
|
|
|
|
|
ucb1400_adc_enable(ucb->ac97);
|
|
ucb1400_adc_enable(ucb->ac97);
|
|
x_res = ucb1400_ts_read_xres(ucb);
|
|
x_res = ucb1400_ts_read_xres(ucb);
|