How to display changing data in XUL - rss

I'm trying to build a firefox extension which can get rss feeds and display them in a popup panel. But I'm not aware about how to display feeds in a panel(I know how to display static text).Because the feed is varying all the time.
Any help regarding this matter will be appreciated.
Thanks in advance.

How about using setInterval to call a function that redraws the panel at the time interval you specify?

You can create DOM elements inside a XUL popup panel using JavaScript, but you have to remember that the panel requires the XHTML namespace:
<panel id="your-id" noautohide="true" xmlns:html="http://www.w3.org/1999/xhtml">
and instead of using:
document.createElement("p"); //for example
you would need to use:
document.createElementNS("http://www.w3.org/1999/xhtml","html:p");
You can get the popup reference by id and just create and append elements as you need them. Then the following might help:
https://developer.mozilla.org/en/XUL/PopupGuide/OpenClose:

Related

Full Calendar/Angular - Handle date cell content when rendering

I'm using the full-calendar component for Angular and I want to customize the content of each date cell according to different conditions. For example if the date is invalid (I have a function that validates the date), I want to change the date's cell background color. Otherwise, if its valid I want to add a plus button inside to add events. Besides that I want to add custom animations and hover effects.
How can I take control of the date is being render ?
I manage to change the background color with dayCellDidMount hook:
dayCellDidMount: (arg) => {
if(!this.dateIsValid(arg.date, arg.isPast)){
arg.el.style.backgroundColor = "#eeeeee";
}
},
I don't think that's the best way to do it and I still can't manage to add the plus button inside the cell.
Can someone achieve this or something similar? Your help would be appreciated, thanks.
If you know another calendar to integrate with Angular that has this features I'm open to suggestions.

How to change the Apache Wicket's CSVDataExporter's link type to a button?

I have a Grid, which have a TopToolbar and BottomToolbar. In the BottomToolbar, I added a CSVDataExporter:
CSVDataExporter csvDataExporter = new CSVDataExporter();
csvDataExporter.setDataFormatNameModel(new ResourceModel("csv.export.link.name"));
csvDataExporter.setDelimiter('|');
addBottomToolbar(new ExportToolbar(this).addDataExporter(csvDataExporter));
I have the link, so I can export the table to CSV fine!
BUT! How could I change the CSV export link to be a Button, but do the same and be at the same place as it was? Thank you!
The Link is generated by your ExportToolbar using the createExportLink method. To generate something else (as in any other component) you can extend the ExportToolbar to override this method. If this is the only place where you need this functionality, you can do so by implementing an anonymous inner class.
Generally you'll want this method to return a Component that has it's own markup, like a Panel, that contains whatever you want to display as your Exportlink or -button.

How to auto-scroll to the bottom of a DevExpress.Web.ASPxHtmlEditor control?

I have been wrestling with this for hours and just can't make it work. I'm using an ASPxHtmlEditor to display (in Preview mode) a dynamically constructed table (that is increasing its rows over the time). I need the control to be scrolled always on the bottom of the table. I have tried using this:
<script type='text/javascript'>window.scrollTo(0, document.body.offsetHeight);</script>
It works on a web page (or a Web Form) but not inside the HTML code in the control. Any help will be much appreciated.
I would use the following bit of code:
http://www.devexpress.com/Support/Center/p/Q207598.aspx

Customize SharePoint:FormFields to a specific height

I'm customizing a NewForm.aspx page and I've created a few new SharePoint:FormFields in the form of textboxes. I'm looking to customize the height of these boxes on a case-by-case basis, but I can't figure it out.
I've looked into DisplaySize, but that only controls the width of a specific textboxe, and I've seen adding in:
style> .ms-long{width:100px;} </style>
but that changes every SharePoint:FormField size, not just one.
Any help would be great! Thanks!
I've done this before using jQuery. With jQuery you can query dom elements (ie. fields) by an attribute of your choice (e.g. the attribute title) and the manipulate it. See Jan Tielens Series about integrating SharePoint and jQuery. http://weblogs.asp.net/jan/archive/2008/11/20/sharepoint-2007-and-jquery-1.aspx
Or just google sharepoint + jquery.

How to change the state in Adobe Flex, using ActionScript?

I`m really new to Flex and ActionScript so please be patient with me.
I want to implement this script: tinyurl.com/yafqrqb
...that is doing this "magic" : tinyurl.com/y9qg32r
...but I want to tweak it a little on InfoWindowTabbedComponent. To be more precisely I`m trying to insert links in that tabs, and when you click one the state will change.
You can see my custom InfoWindowTabbedComponent at the end of the post As you can see, right now I have 2 functions that open url`s.
What I`m trying to do is to change this:
var adobeURL:URLRequest = new URLRequest("http://www.microsoft.com" );
navigateToURL(adobeURL, "_self");
Into something that change the current state.
Can you please help me?
Here`s my custom InfoWindowTabbedComponent: http://pastebin.com/f387bc3b9
I'm not sure I understand what you want to do. If you just want to set the selected Tab, instead of calling navigateToURL() set myTabNavigator.selectedIndex (or selectedChild)
If you really want to change the state, each component has a currentState property, but then you would have to define the states first (via the tag)
And if you really want to navigateToURL() you could navigate to javascript:somefunction() and then set the application state via ExternalInterface, but that would be horribly circumstantial.
Cheers,
Jörg

Resources