Closed Bug 273507 Opened 20 years ago Closed 19 years ago

Add 'set me as being /away' to [some] context menu

Categories

(Other Applications :: ChatZilla, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mnyromyr, Assigned: bugzilla-mozilla-20000923)

Details

(Whiteboard: [cz-patch][cz-0.9.68][cz-0.9.68.4])

Attachments

(4 files, 2 obsolete files)

Now that CZ makes /away states visible in the user list, it would be very
convenient to have a user list context menu item that allows for setting one's
status to /away.
As a first step, a single, "pref'd" message would suffice, but multiple messages
(in a submenu) are an option...
Putting it on the userlist context menu seems wrong, as that could be opened for
any user (so the item would have to be hidden mostly or something).

rginda's original idea (that I remember) was to have the server-nick (the label
to the left of the input) open a popup when clicked.
> Putting it on the userlist context menu seems wrong, as that could be opened
> for any user (so the item would have to be hidden mostly or something).

Granted.

> rginda's original idea (that I remember) was to have the server-nick (the
> label to the left of the input) open a popup when clicked.

Ah, okay, good idea.
Summary: Add 'set me as being /away' to user list context menu → Add 'set me as being /away' to [some] context menu
Assignee: rginda → silver
Status: NEW → ASSIGNED
There's a bunch of whitespace changes in here too, generated by my editor, but
in general it only adds the menu onto a special button (don't ask about why I
had to implement it myself, XUL sucks). Also going in with this is the
downward-pointing arrow image to sit next to the text in the button.

This patch is based on what went into ChatZilla 0.9.68a.
Attachment #182084 - Flags: review?(samuel)
Attachment #182084 - Flags: review?(samuel) → review+
Whiteboard: cz-patch
Attachment #182084 - Flags: approval1.8b2?
Comment on attachment 182084 [details] [diff] [review]
Split /away into /away and /back, and add menu to nickname

a=asa
Attachment #182084 - Flags: approval1.8b2? → approval1.8b2+
Checked in --> part one done.

An automatic nightly ChatZilla build containing this fix will be available in
around 30 minutes from http://twpol.dyndns.org/mozilla/chatzilla/nightly/

Still to do: a list of away messages stored somewhere.
Attachment #183068 - Flags: review?(samuel)
What was wrong with using a <toolbarbutton type="menu">?
For an example, see the Suite sidebar's Tabs button.
a) being unable to find anything in XUL's hidious mess of crap that worked right
at the time.
b) having absolutely no faith in any part of XUL working consistently, reliable
or at all over Mozilla 1.0 to present, thanks to it's inability to do so in
anything I've ever tried that is more complicated than <label/> or <vbox/>.
Attached patch Use a toolbarbutton (obsolete) — Splinter Review
Tested on Mozilla 1.0 using the Classic and Modern themes.
Tested on Suite Trunk using Classic, Modern, Pinball and Toy Factory themes.
Attachment #183142 - Flags: review?(silver)
Whiteboard: cz-patch → [cz-patch][cz-0.9.68]
Attached patch Use toolbarSplinter Review
Also includes the diff for handlers.js which I forgot last time :-[
Attachment #183142 - Attachment is obsolete: true
Attachment #184180 - Flags: review?(silver)
Attachment #183142 - Flags: review?(silver)
Comment on attachment 184180 [details] [diff] [review]
Use toolbar

I guess I'll let you get away with this abuse of XUL, since it has totally
failed to provide anything useful.

r=silver
Attachment #184180 - Flags: review?(silver) → review+
Comment on attachment 184180 [details] [diff] [review]
Use toolbar

Chatzilla-only patch, but not urgent.
Attachment #184180 - Flags: approval1.8b3?
Attachment #184180 - Flags: approval1.8b2?
Comment on attachment 184180 [details] [diff] [review]
Use toolbar

moving request out to b3. We're very nearly wrapped up on 1.8b2.
Attachment #184180 - Flags: approval1.8b2? → approval1.8b2-
Whiteboard: [cz-patch][cz-0.9.68] → [cz-patch][cz-0.9.68][cz-0.9.68.4]
Comment on attachment 184180 [details] [diff] [review]
Use toolbar

a=shaver
Attachment #184180 - Flags: approval1.8b3? → approval1.8b3+
Menu button checked in.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
I haven't got the time to investigate this thoroughly, but it seems the new
version of CZ starts with just an arrow where you'd normally have the nickname,
and no name next to it, in the modern theme. (using a less-than-a-month old
suite nightly build)
The nickname appears when you attempt to connect to any IRC server. However,
even when it does appear, there is no space between the image and the nickname,
making it look ugly and not neat. If what I'm seeing isn't caused by my own
modifications or cvs update screwing up, then I think this bug needs to be reopened.
The lack of nickname is caused by createMenus being after
client.dispatch("set-current-view", { view : client });
Is it safe to create the menus earlier?
No, the menus must be created after the plugins have loaded and run, and they
need to be after we have set the current view.
Attached patch reset label (obsolete) — Splinter Review
Also includes attempt at resolving the label/dropmarker issue.
Attachment #185192 - Flags: review?(silver)
Comment on attachment 185192 [details] [diff] [review]
reset label

>+    // XXX creating the menus clears the nick, reset it
>+    client.statusBar["server-nick"].setAttribute("label", client.prefs["nickname"]);

I think it would be better to actually use the right label when creating the
menu, you know. Just put client.prefs["nickname"] as the label next to the
domID you added, I think.


>+.toolbarbutton-menu-dropmarker {
>+    margin-left: 5px;
>+}

This is no less hacky that what I had before... could you at least use EMs or
something that will not upset people who use varying font sizes?
Attachment #185192 - Flags: review?(silver) → review-
Attachment #185192 - Attachment is obsolete: true
Attachment #185302 - Flags: review?(silver)
Comment on attachment 185302 [details] [diff] [review]
Addressed review comments

r=silver

I still don't like this, it looks horrible, but I suppose it is good the menu
opens more reliably...
Attachment #185302 - Flags: review?(silver) → review+
Attachment #185302 - Flags: approval1.8b3?
Attachment #185302 - Flags: approval1.8b3? → approval1.8b3+
Regression fixes checked in.
Attachment #183068 - Flags: review?(samuel)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: