- Electron version: 1.2.3
- Operating system: OSX 10.11.3

On OSX there is an option to hide an application that's launched automatically on login `Users & Groups > Login Items`. Electron app does not respect this option and displays the main renderer window when launched at login. 

Is there a way to detect either
- that the app was launched at login, or
- that the app was hidden at launch

?

atom/browser/api/atom_api_app.cc
return l10n_util::GetApplicationLocale("");
}
bool App::MakeSingleInstance(
    const ProcessSingleton::NotificationCallback& callback) {
  if (process_singleton_.get())
    return false;
  base::FilePath user_dir;
  PathService::Get(brightray::DIR_USER_DATA, &user_dir);
  process_singleton_.reset(new ProcessSingleton(
      user_dir, base::Bind(NotificationCallbackWrapper, callback)));
  switch (process_singleton_->NotifyOtherProcessOrCreate()) {
    case ProcessSingleton::NotifyResult::LOCK_ERROR:
    case ProcessSingleton::NotifyResult::PROFILE_IN_USE:
    case ProcessSingleton::NotifyResult::PROCESS_NOTIFIED:
      process_singleton_.reset();
      return true;
    case ProcessSingleton::NotifyResult::PROCESS_NONE:
    default:  
      return false;
  }
}
void App::ReleaseSingleInstance() {
  if (process_singleton_.get()) {
    process_singleton_->Cleanup();
    process_singleton_.reset();
  }
}
bool App::Relaunch(mate::Arguments* js_args) {