Linux: enable SxS (side-by-side) support

This also adjusts the logic for .desktop file finding.

BUG=38598
[email protected]

Review URL: https://codereview.chromium.org/145643006

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254788 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/browser/shell_integration_linux.cc b/chrome/browser/shell_integration_linux.cc
index bdd609b..f19a375d 100644
--- a/chrome/browser/shell_integration_linux.cc
+++ b/chrome/browser/shell_integration_linux.cc
@@ -587,7 +587,16 @@
 
 std::string GetDesktopName(base::Environment* env) {
 #if defined(GOOGLE_CHROME_BUILD)
-  return "google-chrome.desktop";
+  chrome::VersionInfo::Channel product_channel(
+      chrome::VersionInfo::GetChannel());
+  switch (product_channel) {
+    case chrome::VersionInfo::CHANNEL_DEV:
+      return "google-chrome-unstable.desktop";
+    case chrome::VersionInfo::CHANNEL_BETA:
+      return "google-chrome-beta.desktop";
+    default:
+      return "google-chrome.desktop";
+  }
 #else  // CHROMIUM_BUILD
   // Allow $CHROME_DESKTOP to override the built-in value, so that development
   // versions can set themselves as the default without interfering with