12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- /*
- * ownCloud Android client application
- *
- * @author David A. Velasco
- * @author Andy Scherzinger
- * Copyright (C) 2015 ownCloud Inc.
- * Copyright (C) 2018 Andy Scherzinger
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2,
- * as published by the Free Software Foundation.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
- package com.owncloud.android.ui.activity;
- import android.app.Activity;
- import android.content.Intent;
- import android.os.Bundle;
- import com.owncloud.android.utils.ClipboardUtil;
- /**
- * Activity copying the text of the received Intent into the system clipboard.
- */
- public class CopyToClipboardActivity extends Activity {
- @Override
- public void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- ClipboardUtil.copyToClipboard(this, getIntent().getCharSequenceExtra(Intent.EXTRA_TEXT).toString());
- finish();
- }
- }
|