From: Taejeong Lee Date: Wed, 6 Mar 2013 07:25:32 +0000 (+0900) Subject: Fix App-control Supports X-Git-Tag: accepted/tizen_2.1/20130425.023916~20^2~12^2~7 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4315d8a28ab5d3a0f9c529b23b256cab7e318231;p=framework%2Fweb%2Fwrt-installer.git Fix App-control Supports * wrt-installer : Some parser related app-control was changed. 'file' sheme is not handled on parsing any more. [Issue#] N/A [Bug] Tizen app-control service doesn't works peroperly on wrt. [Cause] App-control info DB registeration routine was omitted. [Solution] Registration routine was added. Change-Id: I6c7a97ab82651500f31c94c067259437b3e86092 --- diff --git a/src/configuration_parser/widget_parser.cpp b/src/configuration_parser/widget_parser.cpp index 7dc58aa..3b0a0ec 100644 --- a/src/configuration_parser/widget_parser.cpp +++ b/src/configuration_parser/widget_parser.cpp @@ -1093,6 +1093,15 @@ class AppServiceParser : public ElementParser NormalizeString(m_scheme); NormalizeString(m_mime); + // exception + DPL::String ignoreUri(L"file"); + + if (!m_scheme.IsNull() && *m_scheme == ignoreUri) + { + LogInfo("exception : '" << *m_scheme << "' scheme will be ignored."); + m_scheme = DPL::OptionalString::Null; + } + // verify duplicate element DPL::String wildString(L"*/*"); DPL::String nullString(L""); @@ -1271,15 +1280,22 @@ class AppControlParser : public ElementParser virtual void Verify() { + // exception + DPL::String ignoreUri(L"file"); + + if (!m_value.IsNull() && *m_value == ignoreUri) + { + LogInfo("exception : '" << *m_value << "' scheme will be ignored."); + m_value = DPL::OptionalString::Null; + } + if (m_value.IsNull() || *m_value == L"") { return; } DPL::String wildString(L"*/*"); - if ((m_data.m_uriList.find(wildString) == - m_data.m_uriList.end()) - && (m_data.m_uriList.find(*m_value) == - m_data.m_uriList.end())) + if ((m_data.m_uriList.find(wildString) == m_data.m_uriList.end()) + && (m_data.m_uriList.find(*m_value) == m_data.m_uriList.end())) { m_data.m_uriList.insert(*m_value); } else { @@ -1402,16 +1418,6 @@ class AppControlParser : public ElementParser return; } - FOREACH(iterator, m_data.appControlList) { - if (iterator->m_src == m_appControl.m_src && - iterator->m_operation == m_appControl.m_operation) - { - ThrowMsg(Exception::ParseError, - "app control element is duplicated " + - DPL::ToUTF8String(m_appControl.m_src) + ", " + - DPL::ToUTF8String(m_appControl.m_operation)); - } - } m_data.appControlList.push_back(m_appControl); }