Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(164)

Side by Side Diff: ui/base/clipboard/clipboard_aurax11.cc

Issue 12041078: Clear the clipboard closing Incognito window (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Merge with master Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/base/clipboard/clipboard.h" 5 #include "ui/base/clipboard/clipboard.h"
6 6
7 #include <X11/extensions/Xfixes.h> 7 #include <X11/extensions/Xfixes.h>
8 #include <X11/Xatom.h> 8 #include <X11/Xatom.h>
9 #include <list> 9 #include <list>
10 #include <set> 10 #include <set>
(...skipping 867 matching lines...) Expand 10 before | Expand all | Expand 10 after
878 } 878 }
879 879
880 Clipboard::~Clipboard() { 880 Clipboard::~Clipboard() {
881 DCHECK(CalledOnValidThread()); 881 DCHECK(CalledOnValidThread());
882 882
883 // TODO(erg): We need to do whatever the equivalent of 883 // TODO(erg): We need to do whatever the equivalent of
884 // gtk_clipboard_store(clipboard_) is here. When we shut down, we want the 884 // gtk_clipboard_store(clipboard_) is here. When we shut down, we want the
885 // current selection to live on. 885 // current selection to live on.
886 } 886 }
887 887
888 void Clipboard::WriteObjects(Buffer buffer, const ObjectMap& objects) { 888 void Clipboard::WriteObjectsImpl(Buffer buffer, const ObjectMap& objects) {
889 DCHECK(CalledOnValidThread()); 889 DCHECK(CalledOnValidThread());
890 DCHECK(IsValidBuffer(buffer)); 890 DCHECK(IsValidBuffer(buffer));
891 891
892 aurax11_details_->CreateNewClipboardData(); 892 aurax11_details_->CreateNewClipboardData();
893 for (ObjectMap::const_iterator iter = objects.begin(); 893 for (ObjectMap::const_iterator iter = objects.begin();
894 iter != objects.end(); ++iter) { 894 iter != objects.end(); ++iter) {
895 DispatchObject(static_cast<ObjectType>(iter->first), iter->second); 895 DispatchObject(static_cast<ObjectType>(iter->first), iter->second);
896 } 896 }
897 aurax11_details_->TakeOwnershipOfSelection(buffer); 897 aurax11_details_->TakeOwnershipOfSelection(buffer);
898 898
(...skipping 307 matching lines...) Expand 10 before | Expand all | Expand 10 after
1206 return type; 1206 return type;
1207 } 1207 }
1208 1208
1209 // static 1209 // static
1210 const Clipboard::FormatType& Clipboard::GetPepperCustomDataFormatType() { 1210 const Clipboard::FormatType& Clipboard::GetPepperCustomDataFormatType() {
1211 CR_DEFINE_STATIC_LOCAL(FormatType, type, (kMimeTypePepperCustomData)); 1211 CR_DEFINE_STATIC_LOCAL(FormatType, type, (kMimeTypePepperCustomData));
1212 return type; 1212 return type;
1213 } 1213 }
1214 1214
1215 } // namespace ui 1215 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698