cordova.define("cordova-plugin-gntel", function(require, exports, module) {
    module.exports = {
        initCallgate: function (isFirst, successCallback, errorCallback) {
            cordova.exec(successCallback, errorCallback, "GntelPlugin", "initCallgate", [isFirst]);
        },
        
        
        setLogCapacity: function (capacity) {
            cordova.exec(null, null, "GntelPlugin", "setLogCapacity", [capacity]);
        },
        pushGLog: function (type, log) {
            cordova.exec(null, null, "GntelPlugin", "pushGLog", [type, log]);
        },
        getGLog: function (successCallback, errorCallback) {
            cordova.exec(successCallback, errorCallback, "GntelPlugin", "getGLog", []);
        },
        
        setUpdateContentsUrl: function (contentsUrl, successCallback) {
            cordova.exec(successCallback, null, "GntelPlugin", "setUpdateContentsUrl", [contentsUrl]);
        },
        setAllowBeta: function (isAllow, successCallback) {
            cordova.exec(successCallback, null, "GntelPlugin", "setAllowBeta", [isAllow]);
        },
        getUpdateContentsUrl: function (successCallback) {
            cordova.exec(successCallback, null, "GntelPlugin", "getUpdateContentsUrl", []);
        },
        getUpdateContentsVersion: function (successCallback) {
            cordova.exec(successCallback, null, "GntelPlugin", "getUpdateContentsVersion", []);
        },
        updateContents: function (successCallback, errorCallback) {
            cordova.exec(successCallback, errorCallback, "GntelPlugin", "updateContents", []);
        },
        loadLocalFile: function (filePath) {
            cordova.exec(null, null, "GntelPlugin", "loadLocalFile", [filePath]);
        },
        setCallToNumber :  function(toNumber){
            cordova.exec(null, null, "GntelPlugin", "setCallToNumber", [toNumber]);
        },
        installCallGate :  function(){
            cordova.exec(null, null, "GntelPlugin", "installCallGate", null);
        },
        hiddenPopupProfile :  function(){
            cordova.exec(null, null, "GntelPlugin", "hiddenPopupProfile", null);
        },
        setProfileLayout : function(){
            try {
                cordova.exec(null, null, "GntelPlugin", "setProfileLayout", [profile_incoming_top,profile_incoming_height,profile_incoming_width,profile_outgoing_top,profile_outgoing_height,profile_outgoing_width]);
            } catch (error) {
                console.warn("profile 설정 변수 is not defined");
            }
        },
        putPreferences : function(values, successCallback, errorCallback){
            try {
                cordova.exec((successCallback||null), (errorCallback||null), "GntelPlugin", "putPreferences", values);
            } catch (error) {
            }
        }
    };
});
