On uninstall, delete shortcuts first, and then remove directory only if empty.
On uninstall, delete shortcuts first, and then remove directory only if empty.

Previously, ShellUtil::RemoveShortcuts() simply wipes out the entire directory if |location| is SHORTCUT_LOCATION_START_MENU or SHORTCUT_LOCATION_APP_SHORTCUTS, for efficiency. But we're now writing code to migrate shortcuts on the self-destruct flow. In this case, wiping out the directory would destroy our results. Therefore the new logic for deletion of these directories are:
- Use same code to remove Chrome-specific shortcuts (this is what's done for other diretories, e.g., Start Menu).
- If the directory becomes empty, then remove it; otherwise do nothing.

The side effect is that if user creates any non-Chrome shortcuts in these directories, then these shortcuts (and the containing directory) will persist after Chrome uninstall. I think this is a pretty normal behavior.

BUG=235857

Review URL: https://chromiumcodereview.appspot.com/22870004

git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@217130 0039d316-1c4b-4281-b951-d872f2087c98

chuan9/chromium-crosswalk,Just-D/chromium-1,crosswalk-project/chromium-crosswalk-efl,Pluto-tv/chromium-crosswalk,Pluto-tv/chromium-crosswalk,dushu1203/chromium.src,krieger-od/nwjs_chromium.src,dushu1203/chromium.src,markYoungH/chromium.src,ChromiumWebApps/chromium,Chilledheart/chromium,M4sse/chromium.src,Jonekee/chromium.src,hgl888/chromium-crosswalk-efl,M4sse/chromium.src,Fireblend/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,Chilledheart/chromium,krieger-od/nwjs_chromium.src,anirudhSK/chromium,TheTypoMaster/chromium-crosswalk,Just-D/chromium-1,Fireblend/chromium-crosswalk,hgl888/chromium-crosswalk-efl,ChromiumWebApps/chromium,mogoweb/chromium-crosswalk,Fireblend/chromium-crosswalk,dednal/chromium.src,patrickm/chromium.src,fujunwei/chromium-crosswalk,Chilledheart/chromium,Fireblend/chromium-crosswalk,Chilledheart/chromium,fujunwei/chromium-crosswalk,M4sse/chromium.src,Just-D/chromium-1,littlstar/chromium.src,ondra-novak/chromium.src,dednal/chromium.src,dushu1203/chromium.src,patrickm/chromium.src,mohamed--abdel-maksoud/chromium.src,axinging/chromium-crosswalk,PeterWangIntel/chromium-crosswalk,krieger-od/nwjs_chromium.src,bright-sparks/chromium-spacewalk,Just-D/chromium-1,dushu1203/chromium.src,Jonekee/chromium.src,Jonekee/chromium.src,jaruba/chromium.src,ChromiumWebApps/chromium,hgl888/chromium-crosswalk-efl,ChromiumWebApps/chromium,littlstar/chromium.src,chuan9/chromium-crosswalk,Chilledheart/chromium,krieger-od/nwjs_chromium.src,hgl888/chromium-crosswalk-efl,crosswalk-project/chromium-crosswalk-efl,fujunwei/chromium-crosswalk,markYoungH/chromium.src,TheTypoMaster/chromium-crosswalk,Jonekee/chromium.src,markYoungH/chromium.src,crosswalk-project/chromium-crosswalk-efl,markYoungH/chromium.src,ltilve/chromium,patrickm/chromium.src,crosswalk-project/chromium-crosswalk-efl,fujunwei/chromium-crosswalk,hgl888/chromium-crosswalk,krieger-od/nwjs_chromium.src,ChromiumWebApps/chromium,PeterWangIntel/chromium-crosswalk,dushu1203/chromium.src,markYoungH/chromium.src,hgl888/chromium-crosswalk-efl,ondra-novak/chromium.src,littlstar/chromium.src,mohamed--abdel-maksoud/chromium.src,ondra-novak/chromium.src,ltilve/chromium,bright-sparks/chromium-spacewalk,fujunwei/chromium-crosswalk,M4sse/chromium.src,axinging/chromium-crosswalk,hgl888/chromium-crosswalk-efl,dushu1203/chromium.src,mogoweb/chromium-crosswalk,jaruba/chromium.src,axinging/chromium-crosswalk,hgl888/chromium-crosswalk,chuan9/chromium-crosswalk,patrickm/chromium.src,M4sse/chromium.src,markYoungH/chromium.src,Pluto-tv/chromium-crosswalk,Chilledheart/chromium,dushu1203/chromium.src,Just-D/chromium-1,mohamed--abdel-maksoud/chromium.src,hgl888/chromium-crosswalk,M4sse/chromium.src,bright-sparks/chromium-spacewalk,dushu1203/chromium.src,chuan9/chromium-crosswalk,Pluto-tv/chromium-crosswalk,PeterWangIntel/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,crosswalk-project/chromium-crosswalk-efl,TheTypoMaster/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,bright-sparks/chromium-spacewalk,hgl888/chromium-crosswalk-efl,anirudhSK/chromium,littlstar/chromium.src,mogoweb/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,Fireblend/chromium-crosswalk,dushu1203/chromium.src,krieger-od/nwjs_chromium.src,crosswalk-project/chromium-crosswalk-efl,hgl888/chromium-crosswalk,fujunwei/chromium-crosswalk,M4sse/chromium.src,Pluto-tv/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,Chilledheart/chromium,mohamed--abdel-maksoud/chromium.src,jaruba/chromium.src,Jonekee/chromium.src,chuan9/chromium-crosswalk,anirudhSK/chromium,PeterWangIntel/chromium-crosswalk,krieger-od/nwjs_chromium.src,Just-D/chromium-1,dednal/chromium.src,mogoweb/chromium-crosswalk,hgl888/chromium-crosswalk,Just-D/chromium-1,mogoweb/chromium-crosswalk,Fireblend/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,jaruba/chromium.src,ChromiumWebApps/chromium,PeterWangIntel/chromium-crosswalk,jaruba/chromium.src,littlstar/chromium.src,jaruba/chromium.src,ondra-novak/chromium.src,ChromiumWebApps/chromium,chuan9/chromium-crosswalk,littlstar/chromium.src,anirudhSK/chromium,markYoungH/chromium.src,TheTypoMaster/chromium-crosswalk,axinging/chromium-crosswalk,hgl888/chromium-crosswalk-efl,Just-D/chromium-1,crosswalk-project/chromium-crosswalk-efl,anirudhSK/chromium,fujunwei/chromium-crosswalk,anirudhSK/chromium,patrickm/chromium.src,ltilve/chromium,littlstar/chromium.src,PeterWangIntel/chromium-crosswalk,axinging/chromium-crosswalk,mogoweb/chromium-crosswalk,Chilledheart/chromium,mohamed--abdel-maksoud/chromium.src,mogoweb/chromium-crosswalk,ondra-novak/chromium.src,dednal/chromium.src,jaruba/chromium.src,dednal/chromium.src,bright-sparks/chromium-spacewalk,Chilledheart/chromium,Jonekee/chromium.src,mohamed--abdel-maksoud/chromium.src,TheTypoMaster/chromium-crosswalk,bright-sparks/chromium-spacewalk,anirudhSK/chromium,Jonekee/chromium.src,ltilve/chromium,jaruba/chromium.src,Pluto-tv/chromium-crosswalk,axinging/chromium-crosswalk,PeterWangIntel/chromium-crosswalk,Pluto-tv/chromium-crosswalk,hgl888/chromium-crosswalk,ltilve/chromium,krieger-od/nwjs_chromium.src,crosswalk-project/chromium-crosswalk-efl,Fireblend/chromium-crosswalk,ChromiumWebApps/chromium,ltilve/chromium,mogoweb/chromium-crosswalk,ChromiumWebApps/chromium,dednal/chromium.src,anirudhSK/chromium,ondra-novak/chromium.src,dednal/chromium.src,patrickm/chromium.src,Jonekee/chromium.src,M4sse/chromium.src,hgl888/chromium-crosswalk-efl,axinging/chromium-crosswalk,anirudhSK/chromium,dushu1203/chromium.src,dednal/chromium.src,Pluto-tv/chromium-crosswalk,chuan9/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,Jonekee/chromium.src,ltilve/chromium,axinging/chromium-crosswalk,jaruba/chromium.src,anirudhSK/chromium,ltilve/chromium,axinging/chromium-crosswalk,M4sse/chromium.src,markYoungH/chromium.src,Jonekee/chromium.src,bright-sparks/chromium-spacewalk,axinging/chromium-crosswalk,markYoungH/chromium.src,anirudhSK/chromium,mohamed--abdel-maksoud/chromium.src,dednal/chromium.src,Jonekee/chromium.src,ChromiumWebApps/chromium,hgl888/chromium-crosswalk,jaruba/chromium.src,chuan9/chromium-crosswalk,ltilve/chromium,fujunwei/chromium-crosswalk,M4sse/chromium.src,Pluto-tv/chromium-crosswalk,hgl888/chromium-crosswalk,patrickm/chromium.src,PeterWangIntel/chromium-crosswalk,bright-sparks/chromium-spacewalk,PeterWangIntel/chromium-crosswalk,mogoweb/chromium-crosswalk,fujunwei/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,jaruba/chromium.src,dednal/chromium.src,hgl888/chromium-crosswalk-efl,dushu1203/chromium.src,mogoweb/chromium-crosswalk,axinging/chromium-crosswalk,M4sse/chromium.src,ondra-novak/chromium.src,patrickm/chromium.src,krieger-od/nwjs_chromium.src,ChromiumWebApps/chromium,markYoungH/chromium.src,krieger-od/nwjs_chromium.src,Fireblend/chromium-crosswalk,crosswalk-project/chromium-crosswalk-efl,krieger-od/nwjs_chromium.src,hgl888/chromium-crosswalk,ondra-novak/chromium.src,ChromiumWebApps/chromium,markYoungH/chromium.src,patrickm/chromium.src,bright-sparks/chromium-spacewalk,Fireblend/chromium-crosswalk,anirudhSK/chromium,chuan9/chromium-crosswalk,Just-D/chromium-1,littlstar/chromium.src,dednal/chromium.src,ondra-novak/chromium.src