<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=utf-8" http-equiv=Content-Type>
<STYLE>
BLOCKQUOTE {
        MARGIN-BOTTOM: 0px; MARGIN-LEFT: 2em; MARGIN-TOP: 0px
}
OL {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
UL {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
P {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
BODY {
        FONT-SIZE: 10.5pt; FONT-FAMILY: 微软雅黑; COLOR: #000000; LINE-HEIGHT: 1.5
}
</STYLE>

<META name=GENERATOR content="MSHTML 11.00.9600.16384"></HEAD>
<BODY style="MARGIN: 10px">
<DIV>
<DIV>    My code just like:</DIV>
<DIV> </DIV>
<DIV>    QDBusMessage message = 
QDBusMessage::createMethodCall("org.nemomobile.lipstick",</DIV>
<DIV style="TEXT-INDENT: 14em">"/org/nemomobile/lipstick/screenshot",</DIV>
<DIV style="TEXT-INDENT: 14em"> "org.nemomobile.lipstick",</DIV>
<DIV style="TEXT-INDENT: 14em">"saveScreenshot" );</DIV>
<DIV>    QDBusConnection conn =  
QDBusConnection::sessionBus();</DIV>
<DIV>    conn.send(message);</DIV>
<DIV> </DIV>
<DIV>   But it still block the UI ( screen will not response within a 
few seconds)</DIV>
<DIV>   Please help!Thanks very much.</DIV></DIV>
<DIV> </DIV>
<HR style="HEIGHT: 1px; WIDTH: 210px" align=left color=#b5c4df SIZE=1>

<DIV><SPAN>
<DIV style="FONT-SIZE: 10pt; FONT-FAMILY: verdana; MARGIN: 10px">
<DIV>ma xinjun</DIV></DIV></SPAN></DIV>
<DIV> </DIV>
<DIV 
style="BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; BORDER-BOTTOM: medium none; PADDING-BOTTOM: 0cm; PADDING-TOP: 3pt; PADDING-LEFT: 0cm; BORDER-LEFT: medium none; PADDING-RIGHT: 0cm">
<DIV 
style="FONT-SIZE: 12px; FONT-FAMILY: tahoma; BACKGROUND: #efefef; COLOR: #000000; PADDING-BOTTOM: 8px; PADDING-TOP: 8px; PADDING-LEFT: 8px; PADDING-RIGHT: 8px">
<DIV><B>From:</B> <A href="mailto:david.greaves@jolla.com">David 
Greaves</A></DIV>
<DIV><B>Date:</B> 2014-02-12 17:23</DIV>
<DIV><B>To:</B> <A href="mailto:devel@lists.sailfishos.org">Sailfish OS 
Developers</A></DIV>
<DIV><B>Subject:</B> Re: [SailfishDevel] How to get the screen capture but 
don't block UI</DIV></DIV></DIV>
<DIV>
<DIV>Correct</DIV>
<DIV> </DIV>
<DIV>David</DIV>
<DIV> </DIV>
<DIV>On 12/02/14 06:46, Andrey Kozhevnikov wrote:</DIV>
<DIV>> using Qt DBus classes and not use system() call?</DIV>
<DIV>> </DIV>
<DIV>> On 12.02.2014 12:08, itviewer wrote:</DIV>
<DIV>>> Dear all,</DIV>
<DIV>>>  </DIV>
<DIV>>> I need the screen capture function in my application . There are 
two</DIV>
<DIV>>> applications (screenshot and  opensource sailshotme) in the 
jolla store.</DIV>
<DIV>>>  </DIV>
<DIV>>> From the "sailshotme", I know that  can call the 
saveScreenshot method of</DIV>
<DIV>>> org.nemomobile.lipstick through dbus, such as the command:</DIV>
<DIV>>>  </DIV>
<DIV>>> "dbus-send --session --type=method_call --print-reply</DIV>
<DIV>>> --dest=org.nemomobile.lipstick 
/org/nemomobile/lipstick/screenshot</DIV>
<DIV>>> org.nemomobile.lipstick.saveScreenshot  
string:/home/nemo/Pictures/123.png "</DIV>
<DIV>>>  </DIV>
<DIV>>> but, using the "sailshotme" or the above mentioned command will 
lead to the UI</DIV>
<DIV>>> blocking of sailfish system, the screen will not response 
within</DIV>
<DIV>>> a few seconds, however, it seems that there is no such blocking 
when using the</DIV>
<DIV>>> "screenshot".</DIV>
<DIV>>> so I want to know the mechanism of the "screenshot"?</DIV>
<DIV>>>  </DIV>
<DIV>>> Best&Regards</DIV>
<DIV>>>  </DIV>
<DIV>>> 
--------------------------------------------------------------------------------</DIV>
<DIV>>> ma xinjun</DIV>
<DIV>>></DIV>
<DIV>>></DIV>
<DIV>>> _______________________________________________</DIV>
<DIV>>> SailfishOS.org Devel mailing list</DIV>
<DIV>> </DIV>
<DIV>> </DIV>
<DIV>> </DIV>
<DIV>> _______________________________________________</DIV>
<DIV>> SailfishOS.org Devel mailing list</DIV>
<DIV>> </DIV>
<DIV> </DIV>
<DIV>_______________________________________________</DIV>
<DIV>SailfishOS.org Devel mailing list</DIV></DIV></BODY></HTML>