Commit 42466507 authored by Ivan.Shulga's avatar Ivan.Shulga Committed by Alexander Trofimov

try to compile on Ubuntu

git-svn-id: svn://fileserver/activex/AVS/Sources/TeamlabOffice/trunk/ServerComponents@56463 954022d7-b5bf-4e40-9824-e11837661b57
parent 191e99fb
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
#include "third_party/skia/include/core/SkColor.h" #include "third_party/skia/include/core/SkColor.h"
#include "third_party/skia/include/core/SkDevice.h" #include "third_party/skia/include/core/SkDevice.h"
#include "third_party/skia/include/core/SkPreConfig.h" #include "third_party/skia/include/core/skpreconfig.h"
class SkMatrix; class SkMatrix;
class SkMetaData; class SkMetaData;
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
#ifndef SkTypes_DEFINED #ifndef SkTypes_DEFINED
#define SkTypes_DEFINED #define SkTypes_DEFINED
#include "SkPreConfig.h" #include "skpreconfig.h"
#include "SkUserConfig.h" #include "SkUserConfig.h"
#include "SkPostConfig.h" #include "SkPostConfig.h"
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#include "base/logging.h" #include "base/logging.h"
#include "base/memory/singleton.h" #include "base/memory/singleton.h"
#include "base/utf_string_conversions.h" #include "base/utf_string_conversions.h"
#include "third_party/skia/include/core/SkBitmap.h" //#include "third_party/skia/include/core/SkBitmap.h"
#include "ui/base/clipboard/custom_data_helper.h" #include "ui/base/clipboard/custom_data_helper.h"
#include "ui/base/gtk/gtk_signal.h" #include "ui/base/gtk/gtk_signal.h"
#include "ui/base/gtk/scoped_gobject.h" #include "ui/base/gtk/scoped_gobject.h"
...@@ -100,7 +100,7 @@ GdkFilterReturn SelectionChangeObserver::OnXEvent(GdkXEvent* xevent, ...@@ -100,7 +100,7 @@ GdkFilterReturn SelectionChangeObserver::OnXEvent(GdkXEvent* xevent,
} else if (ev->selection == XA_PRIMARY) { } else if (ev->selection == XA_PRIMARY) {
primary_sequence_number_++; primary_sequence_number_++;
} else { } else {
DLOG(ERROR) << "Unexpected selection atom: " << ev->selection; //DLOG(ERROR) << "Unexpected selection atom: " << ev->selection;
} }
} }
return GDK_FILTER_CONTINUE; return GDK_FILTER_CONTINUE;
...@@ -208,20 +208,20 @@ bool Clipboard::FormatType::Equals(const FormatType& other) const { ...@@ -208,20 +208,20 @@ bool Clipboard::FormatType::Equals(const FormatType& other) const {
} }
Clipboard::Clipboard() : clipboard_data_(NULL) { Clipboard::Clipboard() : clipboard_data_(NULL) {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
clipboard_ = gtk_clipboard_get(GDK_SELECTION_CLIPBOARD); clipboard_ = gtk_clipboard_get(GDK_SELECTION_CLIPBOARD);
primary_selection_ = gtk_clipboard_get(GDK_SELECTION_PRIMARY); primary_selection_ = gtk_clipboard_get(GDK_SELECTION_PRIMARY);
} }
Clipboard::~Clipboard() { Clipboard::~Clipboard() {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
gtk_clipboard_store(clipboard_); gtk_clipboard_store(clipboard_);
} }
void Clipboard::WriteObjectsImpl(Buffer buffer, void Clipboard::WriteObjectsImpl(Buffer buffer,
const ObjectMap& objects, const ObjectMap& objects,
SourceTag tag) { SourceTag tag) {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
clipboard_data_ = new TargetMap(); clipboard_data_ = new TargetMap();
for (ObjectMap::const_iterator iter = objects.begin(); for (ObjectMap::const_iterator iter = objects.begin();
...@@ -368,7 +368,7 @@ void Clipboard::WriteSourceTag(SourceTag tag) { ...@@ -368,7 +368,7 @@ void Clipboard::WriteSourceTag(SourceTag tag) {
// and does not always refresh the cache when it is appropriate. // and does not always refresh the cache when it is appropriate.
bool Clipboard::IsFormatAvailable(const Clipboard::FormatType& format, bool Clipboard::IsFormatAvailable(const Clipboard::FormatType& format,
Clipboard::Buffer buffer) const { Clipboard::Buffer buffer) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
GtkClipboard* clipboard = LookupBackingClipboard(buffer); GtkClipboard* clipboard = LookupBackingClipboard(buffer);
if (clipboard == NULL) if (clipboard == NULL)
return false; return false;
...@@ -419,7 +419,7 @@ bool Clipboard::IsFormatAvailable(const Clipboard::FormatType& format, ...@@ -419,7 +419,7 @@ bool Clipboard::IsFormatAvailable(const Clipboard::FormatType& format,
} }
void Clipboard::Clear(Clipboard::Buffer buffer) { void Clipboard::Clear(Clipboard::Buffer buffer) {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
GtkClipboard* clipboard = LookupBackingClipboard(buffer); GtkClipboard* clipboard = LookupBackingClipboard(buffer);
if (clipboard == NULL) if (clipboard == NULL)
return; return;
...@@ -429,9 +429,9 @@ void Clipboard::Clear(Clipboard::Buffer buffer) { ...@@ -429,9 +429,9 @@ void Clipboard::Clear(Clipboard::Buffer buffer) {
void Clipboard::ReadAvailableTypes(Clipboard::Buffer buffer, void Clipboard::ReadAvailableTypes(Clipboard::Buffer buffer,
std::vector<string16>* types, std::vector<string16>* types,
bool* contains_filenames) const { bool* contains_filenames) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
if (!types || !contains_filenames) { if (!types || !contains_filenames) {
NOTREACHED(); //NOTREACHED();
return; return;
} }
...@@ -462,7 +462,7 @@ void Clipboard::ReadAvailableTypes(Clipboard::Buffer buffer, ...@@ -462,7 +462,7 @@ void Clipboard::ReadAvailableTypes(Clipboard::Buffer buffer,
void Clipboard::ReadText(Clipboard::Buffer buffer, string16* result) const { void Clipboard::ReadText(Clipboard::Buffer buffer, string16* result) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
GtkClipboard* clipboard = LookupBackingClipboard(buffer); GtkClipboard* clipboard = LookupBackingClipboard(buffer);
if (clipboard == NULL) if (clipboard == NULL)
return; return;
...@@ -480,7 +480,7 @@ void Clipboard::ReadText(Clipboard::Buffer buffer, string16* result) const { ...@@ -480,7 +480,7 @@ void Clipboard::ReadText(Clipboard::Buffer buffer, string16* result) const {
void Clipboard::ReadAsciiText(Clipboard::Buffer buffer, void Clipboard::ReadAsciiText(Clipboard::Buffer buffer,
std::string* result) const { std::string* result) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
GtkClipboard* clipboard = LookupBackingClipboard(buffer); GtkClipboard* clipboard = LookupBackingClipboard(buffer);
if (clipboard == NULL) if (clipboard == NULL)
return; return;
...@@ -500,7 +500,7 @@ void Clipboard::ReadAsciiText(Clipboard::Buffer buffer, ...@@ -500,7 +500,7 @@ void Clipboard::ReadAsciiText(Clipboard::Buffer buffer,
void Clipboard::ReadHTML(Clipboard::Buffer buffer, string16* markup, void Clipboard::ReadHTML(Clipboard::Buffer buffer, string16* markup,
std::string* src_url, uint32* fragment_start, std::string* src_url, uint32* fragment_start,
uint32* fragment_end) const { uint32* fragment_end) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
markup->clear(); markup->clear();
if (src_url) if (src_url)
src_url->clear(); src_url->clear();
...@@ -534,19 +534,22 @@ void Clipboard::ReadHTML(Clipboard::Buffer buffer, string16* markup, ...@@ -534,19 +534,22 @@ void Clipboard::ReadHTML(Clipboard::Buffer buffer, string16* markup,
markup->resize(markup->length() - 1); markup->resize(markup->length() - 1);
*fragment_start = 0; *fragment_start = 0;
DCHECK(markup->length() <= kuint32max); //DCHECK(markup->length() <= kuint32max);
*fragment_end = static_cast<uint32>(markup->length()); *fragment_end = static_cast<uint32>(markup->length());
gtk_selection_data_free(data); gtk_selection_data_free(data);
} }
void Clipboard::ReadRTF(Buffer buffer, std::string* result) const { void Clipboard::ReadRTF(Buffer buffer, std::string* result) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
ReadData(GetRtfFormatType(), result); ReadData(GetRtfFormatType(), result);
} }
SkBitmap Clipboard::ReadImage(Buffer buffer) const { //SkBitmap
DCHECK(CalledOnValidThread()); bool Clipboard::ReadImage(Buffer buffer) const {
return true;
/*
//DCHECK(CalledOnValidThread());
ScopedGObject<GdkPixbuf>::Type pixbuf( ScopedGObject<GdkPixbuf>::Type pixbuf(
gtk_clipboard_wait_for_image(clipboard_)); gtk_clipboard_wait_for_image(clipboard_));
if (!pixbuf.get()) if (!pixbuf.get())
...@@ -563,12 +566,13 @@ SkBitmap Clipboard::ReadImage(Buffer buffer) const { ...@@ -563,12 +566,13 @@ SkBitmap Clipboard::ReadImage(Buffer buffer) const {
cairo_paint(context); cairo_paint(context);
} }
return canvas.ExtractImageRep().sk_bitmap(); return canvas.ExtractImageRep().sk_bitmap();
*/
} }
void Clipboard::ReadCustomData(Buffer buffer, void Clipboard::ReadCustomData(Buffer buffer,
const string16& type, const string16& type,
string16* result) const { string16* result) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
GtkClipboard* clipboard = LookupBackingClipboard(buffer); GtkClipboard* clipboard = LookupBackingClipboard(buffer);
if (!clipboard) if (!clipboard)
return; return;
...@@ -585,7 +589,7 @@ void Clipboard::ReadCustomData(Buffer buffer, ...@@ -585,7 +589,7 @@ void Clipboard::ReadCustomData(Buffer buffer,
void Clipboard::ReadBookmark(string16* title, std::string* url) const { void Clipboard::ReadBookmark(string16* title, std::string* url) const {
// TODO(estade): implement this. // TODO(estade): implement this.
NOTIMPLEMENTED(); //NOTIMPLEMENTED();
} }
void Clipboard::ReadData(const FormatType& format, std::string* result) const { void Clipboard::ReadData(const FormatType& format, std::string* result) const {
...@@ -595,7 +599,7 @@ void Clipboard::ReadData(const FormatType& format, std::string* result) const { ...@@ -595,7 +599,7 @@ void Clipboard::ReadData(const FormatType& format, std::string* result) const {
void Clipboard::ReadDataImpl(Buffer buffer, void Clipboard::ReadDataImpl(Buffer buffer,
const FormatType& format, const FormatType& format,
std::string* result) const { std::string* result) const {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
result->clear(); result->clear();
GtkClipboard* clipboard = LookupBackingClipboard(buffer); GtkClipboard* clipboard = LookupBackingClipboard(buffer);
GtkSelectionData* data = GtkSelectionData* data =
...@@ -615,7 +619,7 @@ SourceTag Clipboard::ReadSourceTag(Buffer buffer) const { ...@@ -615,7 +619,7 @@ SourceTag Clipboard::ReadSourceTag(Buffer buffer) const {
} }
uint64 Clipboard::GetSequenceNumber(Buffer buffer) { uint64 Clipboard::GetSequenceNumber(Buffer buffer) {
DCHECK(CalledOnValidThread()); //DCHECK(CalledOnValidThread());
if (buffer == BUFFER_STANDARD) if (buffer == BUFFER_STANDARD)
return SelectionChangeObserver::GetInstance()->clipboard_sequence_number(); return SelectionChangeObserver::GetInstance()->clipboard_sequence_number();
else else
...@@ -695,7 +699,7 @@ const Clipboard::FormatType& Clipboard::GetSourceTagFormatType() { ...@@ -695,7 +699,7 @@ const Clipboard::FormatType& Clipboard::GetSourceTagFormatType() {
void Clipboard::InsertMapping(const char* key, void Clipboard::InsertMapping(const char* key,
char* data, char* data,
size_t data_len) { size_t data_len) {
DCHECK(clipboard_data_->find(key) == clipboard_data_->end()); //DCHECK(clipboard_data_->find(key) == clipboard_data_->end());
(*clipboard_data_)[key] = std::make_pair(data, data_len); (*clipboard_data_)[key] = std::make_pair(data, data_len);
} }
...@@ -706,7 +710,8 @@ GtkClipboard* Clipboard::LookupBackingClipboard(Buffer clipboard) const { ...@@ -706,7 +710,8 @@ GtkClipboard* Clipboard::LookupBackingClipboard(Buffer clipboard) const {
case BUFFER_SELECTION: case BUFFER_SELECTION:
return primary_selection_; return primary_selection_;
default: default:
NOTREACHED(); //NOTREACHED();
break;
return NULL; return NULL;
} }
} }
......
...@@ -140,9 +140,9 @@ class UI_EXPORT ImageSkia { ...@@ -140,9 +140,9 @@ class UI_EXPORT ImageSkia {
private: private:
friend class test::TestOnThread; friend class test::TestOnThread;
FRIEND_TEST_ALL_PREFIXES(ImageSkiaTest, EmptyOnThreadTest); //FRIEND_TEST_ALL_PREFIXES(ImageSkiaTest, EmptyOnThreadTest);
FRIEND_TEST_ALL_PREFIXES(ImageSkiaTest, StaticOnThreadTest); //FRIEND_TEST_ALL_PREFIXES(ImageSkiaTest, StaticOnThreadTest);
FRIEND_TEST_ALL_PREFIXES(ImageSkiaTest, SourceOnThreadTest); //FRIEND_TEST_ALL_PREFIXES(ImageSkiaTest, SourceOnThreadTest);
// Initialize ImageSkiaStorage with passed in parameters. // Initialize ImageSkiaStorage with passed in parameters.
// If the image rep's bitmap is empty, ImageStorage is set to NULL. // If the image rep's bitmap is empty, ImageStorage is set to NULL.
......
...@@ -284,9 +284,9 @@ struct GLSurfaceHandle { ...@@ -284,9 +284,9 @@ struct GLSurfaceHandle {
transport_type(transport_), transport_type(transport_),
parent_gpu_process_id(0), parent_gpu_process_id(0),
parent_client_id(0) { parent_client_id(0) {
DCHECK(!is_null() || handle == kNullPluginWindow); //DCHECK(!is_null() || handle == kNullPluginWindow);
DCHECK(transport_type != TEXTURE_TRANSPORT || //DCHECK(transport_type != TEXTURE_TRANSPORT ||
handle == kNullPluginWindow); // handle == kNullPluginWindow);
} }
bool is_null() const { return transport_type == EMPTY; } bool is_null() const { return transport_type == EMPTY; }
bool is_transport() const { bool is_transport() const {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment