1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 2<html xml:lang="en-US" lang="en-US" xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 5 <meta http-equiv="Content-Style-Type" content="text/css" /> 6 <link rel="stylesheet" href="../../../css/manpage.css" type="text/css" /> 7<title>GetHomeButtonState</title> 8 </head> 9 <body> 10<h1><CODE>nn::applet::CTR::GetHomeButtonState</CODE> Function</h1> 11<h2>Syntax</h2> 12 <div class="section"> 13 <pre class="definition"> 14<a href="../../../nn/applet/CTR/HomeButtonState.html">AppletHomeButtonState</a> GetHomeButtonState( 15 void 16); 17</pre> 18 </div> 19<h2>Arguments</h2> 20 <div class="section"> 21<p>None.</p> 22 </div> 23<h2>Return Values</h2> 24<div class="section">Returns the state. </div> 25<h2>Description</h2> 26 <div class="section"> 27<p>Gets the state of the HOME Button.</p><!-- write here --><P> 28This function can obtain the following values. 29</P><TABLE><THEAD><TR><TH>Value</TH><TH>Description</TH></TR></THEAD><TR><TD>nn::applet::CTR::HOME_BUTTON_NONE</TD><TD>Normal Use</TD></TR><TR><TD>nn::applet::CTR::HOME_BUTTON_SINGLE_PRESSED</TD><TD>Single button press detected.</TD></TR><TR><TD>nn::applet::CTR::HOME_BUTTON_DOUBLE_PRESSED</TD><TD>Double button press detected.</TD></TR></TABLE><P> 30For any state other than <CODE>nn::applet::CTR::HOME_BUTTON_NONE</CODE>, you must call the <a href="../../../nn/applet/CTR/ProcessHomeButton.html"><CODE>nn::applet::CTR::ProcessHomeButton</CODE></a> function after the application has run the necessary processing. 31</P><P> 32However, do not use this function's return value directly to determine if HOME Button processing is required. For that purpose, call the <CODE>nn::applet::CTR::IsExpectedToProcessHomeMenu</CODE> function instead. This takes into account not only the importance of transitioning to the HOME Menu because of a HOME Button press but also similar requests to transition to the HOME Menu from other applets. 33</P><P> 34Once the state value changes to something other than <CODE>nn::applet::CTR::HOME_BUTTON_NONE</CODE>, it stays in that state until you clear this by calling the <a href="../../../nn/applet/CTR/ClearHomeButtonState.html"><CODE>nn::applet::CTR::ClearHomeButtonState</CODE></a> function.(The <a href="../../../nn/applet/CTR/ClearHomeButtonState.html"><CODE>nn::applet::CTR::ClearHomeButtonState</CODE></a> function sets the state back to <CODE>applet::HOME_BUTTON_NONE</CODE>. 35</P><P> 36You can determine from the state whether the HOME Button was single- or double-clicked, but behavior is currently the same no matter the value. 37</P></div> 38<h2>Revision History</h2> 39 <div class="section"> 40 <dl class="history"> 41 <dt>2010/12/01</dt> 42<dd>Added details. 43 </dd> 44 <dt>2010/11/10</dt> 45<dd>Initial version.<br /> 46 </dd> 47 </dl> 48 </div> 49 <hr><p>CONFIDENTIAL</p></body> 50</html> 51