var exec = require('cordova/exec');

module.exports = {
    splashscreen: {
        win: null,

        show: function() {
            win= window.open('splashscreen.html');
        },

        hide: function() {
            win.close();
            win = null;
        }
    }
};

require("cordova/tizen/commandProxy").add("SplashScreen", module.exports);

( function() {

win = null;

module.exports = {
    show: function() {
        if ( win === null ) {
            win = window.open('splashscreen.html');
        }
    },

    hide: function() {
        if ( win !== null ) {
            win.close();
            win = null;
        }
    }
};

require("cordova/tizen/commandProxy").add("SplashScreen", module.exports);

})();

Correct structure, and only ever create one splashscreen window.
Proxy: Correct structure, and only ever create one splashscreen window.
