|
| TalMap SDK Libary Reference |
| XObjectBase::Register_TimerEvent |
| ŸÀÌ¸Ó À̺¥Æ®¸¦ µî·ÏÇÕ´Ï´Ù. |
|
|
|
|
Parameters
| |
| Interval |
| ŸÀÌ¸Ó ÁÖ±â |
| Continne_Event |
|
| ID |
| ŸÀÌ¸Ó ID |
|
|
|
|
Return Value
|
|
Remarks
| |
Register_TimerEvent ´Â XObjectBase ÀÇ Method·Î Á¦°øµË´Ï´Ù.
»ç¿ëÀÚ´Â ÀÌ ¸Þ¼Òµå¸¦ ÀÌ¿ëÇÏ¿© °³Ã¼¿¡ ŸÀÌ¸Ó À̺¥Æ®¸¦ µî·ÏÇÒ ¼ö ÀÖ½À´Ï´Ù.
|
|
|
|
Example
| |
|
|
<html>
<head>
<script language="javascript">
<!--
function MapEvent_OnTimer(Flag)
{
// Flag °ªÀ¸·Î ŸÀÌ¸Ó ±¸ºÐ
if (999 == Flag)
{
alert("ŸÀÌ¸Ó À̺¥Æ® ¹ß»ý");
}
}
function RegisterTimer()
{
var ctrlman = m_Map.GetCtrlman();
var poiman = ctrlman.GetPOIMan();
// ŸÀÌ¸Ó µî·Ï
poiman.Register_TimerEvent(1000, 1, 999);
...
// ŸÀÌ¸Ó ÇØÁ¦
poiman.Unregister_TimerEvent(999);
}
-->
</script>
<script language="javascript" for="m_Map" event="OnTimerEvent(Flag)">
<!--
MapEvent_OnTimer(Flag);
-->
</script>
</head>
<body>
<table width="100%" height="100%">
<tr>
<td>
<OBJECT ID="Map" CLASSID="CLSID:DD9B48AD-EDDC-4D2C-BD68-D1FB4B382024"
codebase='http://localhost/TalMapX_Web.CAB#version=1,0,0,17' width=100% height=80%>
</OBJECT>
</td>
</tr>
</table>
</body>
</html>
|
|
|
|
#include "CXCtrlMan.h"
#include "CXPOIMan.h"
BEGIN_EVENTSINK_MAP(CSampleDlg, CDialog)
ON_EVENT(CSampleDlg, IDC_TALMAPXCTRL1, 200, CSampleDlg::OnTimerEventTalmapxctrl1, VTS_I4)
END_EVENTSINK_MAP()
#define TIMERID 999
void CSampleDlg::OnTimerEventTalmapxctrl1(long Code)
{
if (TIMERID == Code)
{
AfxMessageBox(_T("ŸÀÌ¸Ó À̺¥Æ® ¹ß»ý"));
}
}
void CSampleDlg::RegisterTimer()
{
CXCtrlMan ctrlman = m_Map.GetCtrlMan();
CXPOIMan poiman = ctrlMan.GetPOIMan();
// ŸÀÌ¸Ó µî·Ï
poiman.Register_TimerEvent(1000, 1, TIMERID);
...
// ŸÀÌ¸Ó ÇØÁ¦
poiman.Unregister_TimerEvent(TIMERID);
}
|
|
|
|
See Also
|
|