#include <vector>
#include <utility>
+#include "common/utils/glist_range.h"
#include "common/utils/manifest_util.h"
namespace bf = boost::filesystem;
using CertInfo = common_installer::CertificateInfo;
+const char kWidgetApp[] = "widgetapp";
+
bool RegisterCertificate(pkgmgr_instcertinfo_h handle,
const ValidationCore::CertificatePtr& certPtr, pkgmgr_instcert_type type) {
if (certPtr) {
return true;
}
+void AdjustWidgetNodisplayAttr(manifest_x* manifest) {
+ for (auto& app : GListRange<application_x*>(manifest->application)) {
+ if (!strcmp(app->component_type, kWidgetApp)) {
+ free(app->nodisplay);
+ // The nodisplay attribute of widget application should be true,
+ // but nodisplay of widget-service framework uses this attribute
+ // as defined at manifest file. So we need to adjust this value
+ // just before register in pkgmgr db.
+ app->nodisplay = strdup("true");
+ }
+ }
+}
+
} // namespace
namespace common_installer {
manifest->external_path = strdup(ext_path.c_str());
}
+ AdjustWidgetNodisplayAttr(manifest);
+
int ret = request_mode != RequestMode::GLOBAL ?
pkgmgr_parser_process_usr_manifest_x_for_installation(manifest, uid) :
pkgmgr_parser_process_manifest_x_for_installation(manifest);
manifest->external_path = strdup(ext_path.c_str());
}
+ AdjustWidgetNodisplayAttr(manifest);
+
int ret = request_mode != RequestMode::GLOBAL ?
pkgmgr_parser_process_usr_manifest_x_for_upgrade(manifest, uid) :
pkgmgr_parser_process_manifest_x_for_upgrade(manifest);