diff options
Diffstat (limited to 'chrome/common/render_messages.h')
-rw-r--r-- | chrome/common/render_messages.h | 70 |
1 files changed, 0 insertions, 70 deletions
diff --git a/chrome/common/render_messages.h b/chrome/common/render_messages.h index 211297a..c76b430 100644 --- a/chrome/common/render_messages.h +++ b/chrome/common/render_messages.h @@ -595,34 +595,6 @@ struct ViewMsg_New_Params { int64 session_storage_namespace_id; }; -// Message to ask the browser to translate some text from one language to -// another. -struct ViewHostMsg_TranslateTextParam { - // The routing id. Even though ViewHostMsg_TranslateText is a control message - // (sent to the browser, not to a specific RenderViewHost), the browser needs - // the routing id in order to send the response back to the right RenderView. - int routing_id; - - // An id used to identify that specific translation. - int work_id; - - // The id of the page this translation originated from. - int page_id; - - // The text chunks that need to be translated. - std::vector<string16> text_chunks; - - // The ISO code of the language the text to translate is in. - std::string from_language; - - // The ISO code of the language the text should be translated to. - std::string to_language; - - // Whether a secure connection should be used when transmitting the text for - // translation to an external server. - bool secure; -}; - struct ViewHostMsg_RunFileChooser_Params { enum Mode { // Requires that the file exists before allowing the user to pick it. @@ -2569,48 +2541,6 @@ struct ParamTraits<ViewMsg_New_Params> { } }; -template<> -struct ParamTraits<ViewHostMsg_TranslateTextParam> { - typedef ViewHostMsg_TranslateTextParam param_type; - static void Write(Message* m, const param_type& p) { - WriteParam(m, p.routing_id); - WriteParam(m, p.work_id); - WriteParam(m, p.page_id); - WriteParam(m, p.text_chunks); - WriteParam(m, p.from_language); - WriteParam(m, p.to_language); - WriteParam(m, p.secure); - } - - static bool Read(const Message* m, void** iter, param_type* p) { - return - ReadParam(m, iter, &p->routing_id) && - ReadParam(m, iter, &p->work_id) && - ReadParam(m, iter, &p->page_id) && - ReadParam(m, iter, &p->text_chunks) && - ReadParam(m, iter, &p->from_language) && - ReadParam(m, iter, &p->to_language) && - ReadParam(m, iter, &p->secure); - } - static void Log(const param_type& p, std::wstring* l) { - l->append(L"("); - LogParam(p.routing_id, l); - l->append(L", "); - LogParam(p.work_id, l); - l->append(L", "); - LogParam(p.page_id, l); - l->append(L", "); - LogParam(p.text_chunks, l); - l->append(L", "); - LogParam(p.from_language, l); - l->append(L", "); - LogParam(p.to_language, l); - l->append(L", "); - LogParam(p.secure, l); - l->append(L")"); - } -}; - template <> struct SimilarTypeTraits<TranslateErrors::Type> { typedef int Type; |