语言

Menu
Sites
Language
Can I use the ITouchLongPressGestureEventListener and IPropagatedTouchEventListener at the same time?

Hi i`m develope Tizen app.

when i use touch event ITouchLongPressGestureEventListener  and IPropagatedTouchEventListener  on panel.

LongPressGesture didn`t work

Ex:

Tizen::Ui::Controls::Panel* pPanel = Tizen::Ui::Controls::Panel;
pPanel->Construct(myLayout, this->GetBounds());
//Panel initialize;

Tizen::Ui::TouchLongPressGestureDetector* pLongtouchEvent = 
            new Tizen::Ui::TouchLongPressGestureDetector;
if(pLongtouchEvent){
    pLongtouchEvent->Construct();
    pPanel->AddGestureDetector(pLongtouchEvent);
    pLongtouchEvent->AddLongPressGestureEventListner(*this);
}
//add longtouch eventListener on panel 

this->SetPropagatedTouchEventListener(this);
//add progated touch event on frame
this->AddControl(*pPanel);
//add panel on default frame..

that was simple my code..

previewtouch event  of progatedtouchevent called because panel added on frame.

but. prieview touch and longtouch event cann`t called same time.

(sure if i add progated touch event on panel longtouch and progated touch event perform sametime. because bool ontouchpressed() and bool ontouchmoved()

called (previewtouch only called upper component exist but panel upper component didn`t exist))

how can i use OnPreviewTouch function and Longtouch function at the same time?

 

sorry about my awkword english 

编辑者为: kiwoong ko 08 4月, 2015
查看选择的答案

响应

2 回复
Mark as answer
Alex Ashirov

Hi,

What value do you return from the OnPreviewTouch()? Probably you need to return false.

정민 성

OMG.... Thank you. 

We spent more than 15 days because of this problem. But with your help solved. Thanks once again.

Thank you!