emacs mode lines for websockets 2 space indents

RESOLVED FIXED in mozilla8

Status

()

Core
Networking: WebSockets
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: mcmanus, Assigned: mcmanus)

Tracking

unspecified
mozilla8
x86_64
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [inbound])

Attachments

(1 attachment)

bug 664860 changed netwerk/websockets to 2 space indents but did not update the emacs mode lines.
Component: Networking: HTTP → Networking: WebSockets
Depends on: 664860
QA Contact: networking.http → networking.websockets
Created attachment 544533 [details] [diff] [review]
patch 1
Assignee: nobody → mcmanus
Status: NEW → ASSIGNED
Attachment #544533 - Flags: review?(jduell.mcbugs)
Comment on attachment 544533 [details] [diff] [review]
patch 1

>diff --git a/netwerk/protocol/websocket/WebSocketChannel.cpp
>-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
>+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
> /* vim: set sw=2 ts=8 et tw=80 : */

The "canonical" example in the Mozilla Style guide (and what I've used elsewhere in necko) is

/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */

I.e. tab-width is 8.  Doesn't make any difference when indent-tabs-mode is nil, correct?  Except when there are tabs already in file?  I don't know--might as well follow the style guide.


>diff --git a/netwerk/protocol/websocket/nsIWebSocketChannel.idl 
>diff --git a/netwerk/protocol/websocket/nsIWebSocketListener.idl 
>-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
>+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */

I deliberately kept the indenting of the IDL files at 4 spaces.  Maybe that was stupid/arbitrary (logic: IDLs are old-school with the ns-prefix, etc.), but let's not change it now (unless you really want to, but I think I know the answer to that :)   You can change tab-width to 8 for extra-credit.
Attachment #544533 - Flags: review?(jduell.mcbugs) → review+
Whiteboard: [inbound]
http://hg.mozilla.org/mozilla-central/rev/8edd1224feed
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla8
You need to log in before you can comment on or make changes to this bug.