Search Results

Search found 792 results on 32 pages for 'ed sweeney'.

Page 8/32 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • Random pauses with "Key dispatching timed out sending to <null>" when closing Android SurfaceView

    - by kenyee
    When I close an Android SurfaceView Activity, the app sometimes pauses and almost gets an ANR (Application Not Responding) message. Looking at LogCat, it appears to be timing out trying to send keys to it. I tried modifying the code to setFocusable(false) when in the onKeyDown handler for the SurfaceView, but that doesn't seem to affect this. Any other ideas on what might be causing this? Or what these messages in Logcat even mean? ============================= 05-31 19:35:35.285: INFO/WindowManager(586): focus null mToken is null at event dispatch! 05-31 19:35:35.295: WARN/WindowManager(586): Current state: {{KeyEvent{action=1 code=4 repeat=0 meta=0 scancode=158 mFlags=8} to null @ 1275334535292 lw=null lb=null fin=true gfw=true ed=true tts=0 wf=false fp=false mcf=null}} 05-31 19:35:35.305: WARN/WindowManager(586): Continuing to wait for key to be dispatched 05-31 19:35:40.306: WARN/WindowManager(586): Key dispatching timed out sending to 05-31 19:35:40.316: WARN/WindowManager(586): Dispatch state: {{KeyEvent{action=0 code=4 repeat=0 meta=0 scancode=158 mFlags=8} to Window{43763540 com.myapp/com.myapp.DiagramEdit paused=false} @ 1275334499512 lw=Window{43763540 com.myapp/com.myapp.DiagramEdit paused=false} lb=android.os.BinderProxy@43702190 fin=false gfw=true ed=true tts=0 wf=false fp=false mcf=null}} 05-31 19:35:40.326: INFO/WindowManager(586): focus null mToken is null at event dispatch! 05-31 19:35:40.326: WARN/WindowManager(586): Current state: {{KeyEvent{action=1 code=4 repeat=0 meta=0 scancode=158 mFlags=8} to null @ 1275334540327 lw=null lb=null fin=true gfw=true ed=true tts=0 wf=false fp=false mcf=null}} 05-31 19:35:40.326: WARN/WindowManager(586): Continuing to wait for key to be dispatched

    Read the article

  • MMC Snapin development: 'MMC not responding' - Is there a timeout that can be set for debugging?

    - by Ed Sykes
    So I'm writing a snapin for MMC 3. Quite often I have the debugger attached and I'm stepping through some code. MMC has some kind of a fail safe for misbehaving snapins that automatically unloads them after a timeout. The message is 'This snap-in is not responding'. After that MMC can behave as though your snap-in has been unloaded. fair enough, it's not responding because I'm stepping through the debugger. However, the timeout is very small for development. Does anyone know of a way of increasing the timeout? I googled and couldn't find anything. Checking the MMC registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MMC and couldn't see anything there. I also checked the snap-in registry location under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MMC\SnapIns. No luck. I feel like there must be a way of increasing the timeout as this is something the devs as Microsoft must have encountered this problem.

    Read the article

  • How to use Tor control protocol in C#?

    - by Ed
    I'm trying to send commands to the Tor control port programmatically to make it refresh the chain. I haven't been able to find any examples in C#, and my solution's not working. The request times out. I have the service running, and I can see it listening on the control port. public string Refresh() { TcpClient client = new TcpClient("localhost", 9051); string response = string.Empty; string authenticate = MakeTcpRequest("AUTHENTICATE", client); if (authenticate.Equals("250")) response = MakeTcpRequest("SIGNAL NEWNYM", client); client.Close(); return response; } public string MakeTcpRequest(string message, TcpClient client) { client.ReceiveTimeout = 20000; client.SendTimeout = 20000; string proxyResponse = string.Empty; try { // Send message StreamWriter streamWriter = new StreamWriter(client.GetStream()); streamWriter.Write(message); streamWriter.Flush(); // Read response StreamReader streamReader = new StreamReader(client.GetStream()); proxyResponse = streamReader.ReadToEnd(); } catch (Exception ex) { // Ignore } return proxyResponse; } Can anyone spot what I'm doing wrong?

    Read the article

  • List display names from django models

    - by Ed
    I have an object: POP_CULTURE_TYPES = ( ('SG','Song'), ('MV', 'Movie'), ('GM', 'Game'), ('TV', 'TV'), ) class Pop_Culture(models.Model): name = models.CharField(max_length=30, unique=True) type = models.CharField(max_length=2, choices = POP_CULTURE_TYPES, blank=True, null=True) Then I have a function: def choice_list(request, modelname, field_name): mdlnm = get.model('mdb', modelname.lower()) mdlnm = mdlnm.objects.values_list(field_name, flat=True).distinct().order_by(field_name) return render_to_response("choice_list.html", { 'model' : modelname, 'field' : field_name, 'field_list' : mdlnm }) This gives me a distinct list of all the "type" entries in the database in the "field_list" variable passed in render_to_response. But I don't want a list that shows: SG MV I want a list that shows: Song Movie I can do this on an individual object basis if I was in the template object.get_type_display But how do I get a list of all of the unique "type" entries in the database as their full names for output into a template? I hope this question was clearly described. . .

    Read the article

  • WPF RowDetailsTemplate width issue

    - by Ed Courtenay
    Apologies if this is a dupe, but I can't seem to find a rational solution for what must be a fairly simple issue. <Window x:Class="FeedTest.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="MainWindow" Height="350" Width="525"> <Window.Resources> <XmlNamespaceMappingCollection x:Key="map"> <XmlNamespaceMapping Prefix="media" Uri="http://search.yahoo.com/mrss/" /> </XmlNamespaceMappingCollection> <XmlDataProvider x:Key="newsFeed" XPath="//item[string-length(title)>0]" Source="http://newsrss.bbc.co.uk/rss/newsonline_uk_edition/uk/rss.xml" /> <DataTemplate x:Key="rowDetailTemplate"> <Border BorderThickness="2"> <StackPanel Orientation="Horizontal"> <Image Source="{Binding XPath=media:thumbnail/@url}" Width="66" Height="49" /> <StackPanel Orientation="Vertical" Margin="5"> <TextBlock Text="{Binding XPath=description}" TextWrapping="Wrap" /> </StackPanel> </StackPanel> </Border> </DataTemplate> <Style TargetType="{x:Type DataGrid}"> <Setter Property="GridLinesVisibility" Value="None" /> </Style> </Window.Resources> <Grid Binding.XmlNamespaceManager="{StaticResource map}"> <DataGrid AutoGenerateColumns="False" ItemsSource="{Binding Source={StaticResource newsFeed}}" RowDetailsVisibilityMode="VisibleWhenSelected" RowDetailsTemplate="{StaticResource rowDetailTemplate}"> <DataGrid.Columns> <DataGridTextColumn Header="Title" Binding="{Binding XPath=title}" MinWidth="150" Width="*" /> </DataGrid.Columns> </DataGrid> </Grid> The attached XAML gets a news feed, and displays the title of each item in a DataGrid. Selecting an item shows the RowDetailsTemplate which is where my problem lies - why does the RowDetailsTemplate expand beyond the width of the containing DataGrid (thus forcing a horizontal scrollbar), and more importantly, how do I stop it doing this? Many thanks.

    Read the article

  • CGContextDrawPDFPage taking up large amounts of memory

    - by Ed Marty
    I have a PDF file that I want to draw in outline form. I want to draw the first several pages on the document each in their own UIImage to use on a button so that when clicked, the main display will navigate to the clicked page. However, CGContextDrawPDFPage seems to be using copious amounts of memory when attempting to draw the page. Even though the image is only supposed to be around 100px tall, the application crashes while drawing one page in particular, which according to Instruments, allocates about 13 MB of memory just for the one page. Here's the code for drawing: //Note: This is always called in a background thread, but the autorelease pool is setup elsewhere + (void) drawPage:(CGPDFPageRef)m_page inRect:(CGRect)rect inContext:(CGContextRef) g { CGPDFBox box = kCGPDFMediaBox; CGAffineTransform t = CGPDFPageGetDrawingTransform(m_page, box, rect, 0,YES); CGRect pageRect = CGPDFPageGetBoxRect(m_page, box); //Start the drawing CGContextSaveGState(g); //Clip to our bounding box CGContextClipToRect(g, pageRect); //Now we have to flip the origin to top-left instead of bottom left //First: flip y-axix CGContextScaleCTM(g, 1, -1); //Second: move origin CGContextTranslateCTM(g, 0, -rect.size.height); //Now apply the transform to draw the page within the rect CGContextConcatCTM(g, t); //Finally, draw the page //The important bit. Commenting out the following line "fixes" the crashing issue. CGContextDrawPDFPage(g, m_page); CGContextRestoreGState(g); } Is there a better way to draw this image that doesn't take up huge amounts of memory?

    Read the article

  • Can I create a custom plist structure definition?

    - by Ed Marty
    When editing plist files in XCode, it can detect the type of plist and show human-readable strings to make it more easy to edit the file. The Info.plist, for example. Thanks to This question, I found the (or a) place where it stores that structure definition, as InfoPlistStructDefs.xcodeplugin. If I put my own file in there, however, nothing interesting happens. That is, it doesn't show up in the list of possible property list types. So does anybody know how to make XCode or the external property list editor application recognize a custom plist structure definition?

    Read the article

  • AJAX get data from large HTML page as the large HTML page loads

    - by Ed
    Not entirely sure whether this has a name but basically I have a large HTML page that is generated from results in a db. So viewing the HTML page (which is a report) in a browser directly does not display all contents immediately but displays what it has and additional HTML is added as the results from the DB are retrieved... Is there a way I can make an AJAX request to this HTML page and as opposed to waiting until the whole page (report) is ready, I can start processing the response as the HTML report is loaded? Or is there another way of doing it? Atm I make my AJAX response it just sits there for a minute or two until the HTML page is complete... If context is of any use: The HTML report is generated by a Java servlet and the page making the AJAX call is a JSP page. Unfortunately I can't very easily break the report up because it is generated by BIRT (Eclipse reporting extension). Thanks in advance.

    Read the article

  • How to parse a raw HTTP response?

    - by Ed
    If I have a raw HTTP response as a string: HTTP/1.1 200 OK Date: Tue, 11 May 2010 07:28:30 GMT Expires: -1 Cache-Control: private, max-age=0 Content-Type: text/html; charset=UTF-8 Server: gws X-XSS-Protection: 1; mode=block Connection: close <!doctype html><html>...</html> Is there an easy way I can parse it into an HttpListenerResponse object? Or at least some kind .NET object so I don't have to work with raw responses. What I'm doing currently is extracting the header key/value pairs and setting them on the HttpListenerResponse. But some headers can't be set, and then I have to cut out the body of the response and write it to the OutputStream. But the body could be gzipped, or it could be an image, which I can't get to work yet. And some responses contain random characters everywhere, which looks like an encoding problem. It's a lot of trouble. I'm getting a raw response because I'm using SOCKS to send an HTTP request. The program I'm working on is basically an HTTP proxy that can route requests through a SOCKS proxy, like Privoxy does.

    Read the article

  • UpdatePanel doesn't load correctly on second try

    - by Ed Woodcock
    Ok, I've got two UpdatePanels on a (relatively simple) CRUD-management page, and I'm having some issues with them. The first updatepanel fails the second time it's updated (infinite loading popout, page doesn't change, request comes back properly but apparently isn't used). The second updatepanel fails if the first updatepanel has updated first, or if a certain internal trigger is pressed twice. Interestingly, the first updatepanel can be called multiple times with no problems if the first has yet to be called. layout example: <updatepanel> <table> <trigger> </table> </updatepanel> <lightbox> <updatepanel> <multiple triggers> </updatepanel> </lightbox> The use of the second updatepanel is required for the lightbox to function correctly (so it can't just be one big one). The first updatepanel exhibits this behaviour regardless of whether the second is present on the page or not. Has anyone ever experienced similar problems/have any ideas?

    Read the article

  • VisualStudio 2010 Settings Page - Collection Settings

    - by Ed Eichman
    I have a list of Filemaker database names Each DB name has a list of field/attribute pairs associated with it I have a windows form application in C# 4.0 (vs2010) that wants to use the above data I would like to maintain the list either in the Visual Studio settings page, or in one of the standard visual studio settings files using the standard .NET settings calls I would like to avoid writing my own custom settings, xml, xds (to avoid the "Could not find schema information for the element/attribute " errors) I just have a slightly complicated INI file! I don't want to complicate my life! Do any easy solutions exist? Unless someone has a brighter idea, I am simply going to write string settings with names that indicate it's a FM DB (e.g. "fmdbAddresses"), and values that concat my field/attribute pairs (e.g. "gUserResult=skipField|gAddressID=convertToInt|gAddressID=uniqueIx")

    Read the article

  • Encrypting with Perl CBC and decrypting with PHP mcrypt

    - by Ed
    I have an encrypted string that was encrypted with Perl Crypt::CBC (Rijndael,cbc). The original plaintext was encrypted with encrypt_hex() method of Crypt::CBC. $encrypted_string = '52616e646f6d49567b2c89810ceddbe8d182c23ba5f6562a418e318b803a370ea25a6a8cbfe82bc6362f790821dce8441a790a7d25d3d9ea29f86e6685d0796d'; I have the 32 character key that was used. mcrypt is successfully compiled into PHP, but I'm having a very hard time trying to decrypt the string in PHP. I keep getting gibberish back. If I unpack('H*', $encrypted_string), I see 'RandomIV' followed by what looks like binary. I can't seem to correctly extract the IV and separate the actual encrypted message. I know I'm not providing my information, but I'm not sure where else to start. $cipher = 'rijndael-256'; $cipher_mode = 'cbc'; $td = mcrypt_module_open($cipher, '', $cipher_mode, ''); $key = '32 characters'; // Does this need to converted to something else before being passed? $iv = ?? // Not sure how to extract this from $encrypted_string. $token = ?? // Should be a sub-string of $encrypted_string, correct? mcrypt_generic_init($td, $key, $iv); $clear = rtrim(mdecrypt_generic($td, $token), ''); mcrypt_generic_deinit($td); mcrypt_module_close($td); echo $clear; Any help, pointers in the right direction, would be greatly appreciated. Let me know if I need to provide more information.

    Read the article

  • Log in using Java where server's authentication could be sso or web applcation container's basic

    - by Ed
    Hi, I have a situation where ideally I want to be able to log-in to a secure area using a Java application. I would like to make an HTTP request and check the response to see if I need to do some kind of authenication before I can actually get the response expected, instead of effectively some login page. The complication is that the server that responds will not always be the same - the user of the Java app specifies the URL - and the server may be using some kind of single sign on authentication or the web container's. I don't know the field names for the username and password fields or the action of the form, is there a simple way to obtain this kind of information from the URL? I see the URLConnection object has methods getPermission() which has a method getActions() but are not suitable, anything that might be? I guess example things I am looking to determine: Does the response require authentication? If so; what type / which servlet? e.g. j_security_check, josso single sign on, ... And then some way of authenticating the client And finally managing the state of the authenticated user for other requests Do I need to know the attributes of the login form before attemping to login? And then, is the onoly way of verifying permission to the requested resource to manually manage the cookies? Thanks in advance.

    Read the article

  • web.xml - Java Servlet Filters and WebSphere - URL Pattern issues

    - by Ed
    Hi, So we are running a web application that has been tested on Tomcat, Glassfish, WebLogic and WebSphere. All run correctly except WebSphere. The issue is that filters are not processed for files under a certain directory. For example I have a filter that checks the user's lanuage from browser cookies and another that get the user's username, in the web.xml there are configured like so: <!-- ****************************** --> <!-- * Security context filtering * --> <!-- ****************************** --> <filter> <filter-name>SetSecurityContextFilter</filter-name> <filter-class> com.test.security.SecurityContextServletFilter </filter-class> </filter> <!-- ****************************** --> <!-- ** Locale context filtering ** --> <!-- ****************************** --> <filter> <filter-name>SetLocaleFilter</filter-name> <filter-class> com.test.locale.LocaleServletFilter </filter-class> </filter> <filter-mapping> <filter-name>SetSecurityContextFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <filter-mapping> <filter-name>SetLocaleFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> Both filters set a static threadlocal variable which can be accessed from a static getter, but when the same file 'test.jsp' invokes the getters, under 'contextroot/js' they return the default values (as if unset) while under 'contextroot/pages' they are correct. Any ideas? Thanks in advance.

    Read the article

  • Problems importing JAI in Eclipse

    - by Ed Taylor
    I'm trying to use the following import in Eclipse running on Mac OS X 10.6: import javax.media.jai.JAI; Unfortunately, this doesn't work, instead I get the following message: "Access restriction: The type JAI is not accessible due to restriction on required library /System/Library/Java/Extensions/jai_core.jar" How can this be resolved? I want to use JAI.create("fileload", "filename");

    Read the article

  • How to preselect nodes using jsTree jQuery plug-in

    - by Ed Schembor
    I am using the jsTree jQuery plug-in with its "Checkbox" plug-in and using an async http request to lazy-load each level of the tree. All works great, except that I cannot get the tree to pre-select certain nodes after the first level. I am using the "selected" attribute to provide an array of ID's to preselect. ID's in the top level of the tree are correctly pre-selected. However, ID's in lower levels of the tree are not selected when the level loads. Am I missing something? Here is the constructor code: $(sDivID).tree( { data : { async : true, opts : {url : sURL} }, plugins:{ "checkbox" : {three_state : false} }, selected : myArrayOfIDs, ui:{ theme_name : "checkbox", dots : false, animation : 400 }, callback : { beforedata : function(NODE, TREE_OBJ) { return { id : $(NODE).attr("id") || 0, rand : Math.random().toString() } } } } )

    Read the article

  • Internationalized strings in Eclipse plugin.xml file are not found when installed in Eclipse applica

    - by Ed
    Hi, I have created 2 plugins, implementing an ODA driver plugin and its UI plugin for the BIRT extension to Eclipse. My plugins both work as expected when eclipse starts up another eclipse application where I can then test the plugins I am developing. However, when I install my plugins into an Eclipse application and then start it from a Windows shortcut, the plugins work but and language keys specified in the plugin.xml files are not found. For example, in my plugin.xml file for the ODA Driver plugin I set the attributes 'id' to '%oda.data.source.id' and the data source 'defaultDisplayName' to '%data.source.name'. I then, in a file 'language.properties', have defined the values for both of these keys (where the keys don't have the preceeding % character). When running the plugins that have been installed into the dropins/plugins directory of an Eclipse application, the wizard for creating my ODA data source names is as '%data.source.name' and saves the data source in the rptdesign (XML) file with an ID of '%oda.data.source.id'. Since 'language' is not the default name for the properties file I went into the manifest for both plugins and changed the 'Bundle-Localization' attribute to 'language'. The language file is located in the root directory of both of my plugins. The properties file is definitely found, since I use the two language files to store other strings used by the plugins, looked up using a java ResourceBundle. The strings are always found whether the plugins are run from Eclipse application loading another, or when properly installed in the dropins/plugins directory of an Eclipse application. Why are the installed plugins not finding language keys reference in the plugin.xml files? There are not errors in the logs and the language.properties files are clearly accessible... Thanks in advance.

    Read the article

  • How to retrieve a pixel in a tiff image (loaded with JAI)?

    - by Ed Taylor
    I'm using a class (DisplayContainer) to hold a RenderedOp-image that should be displayed to the user: RenderedOp image1 = JAI.create("tiff", params); DisplayContainer d = new DisplayContainer(image1); JScrollPane jsp = new JScrollPane(d); // Create a frame to contain the panel. Frame window = new Frame(); window.add(jsp); window.pack(); window.setVisible(true); The class DisplayContainer looks like this: import java.awt.event.MouseEvent; import java.awt.geom.AffineTransform; import javax.media.jai.RenderedOp; import com.sun.media.jai.widget.DisplayJAI; public class DisplayContainer extends DisplayJAI { private static final long serialVersionUID = 1L; private RenderedOp img; // Affine tranform private final float ratio = 1f; private AffineTransform scaleForm = AffineTransform.getScaleInstance(ratio, ratio); public DisplayContainer(RenderedOp img) { super(img); this.img = img; addMouseListener(this); } public void mouseClicked(MouseEvent e) { System.out.println("Mouseclick at: (" + e.getX() + ", " + e.getY() + ")"); // How to retrieve the RGB-value of the pixel where the click took // place? } // OMISSIONS } What I would like to know is how the RGB value of the clicked pixel can be obtained?

    Read the article

  • Selenium RC test - IE gives 403 error on Tomcat app, Tomcat root OK

    - by Ed Daniel
    I'm new to Selenium RC, having previously used Selenium IDE and only run tests in Firefox. I'm trying to get a basic test to run using Selenium RC through Eclipse; my test works OK in Firefox, and in Safari now that I've killed the pop-up blocker, but IE8 is causing a SeleniumException to be thrown, containing an "XHR ERROR" with a 403 response: com.thoughtworks.selenium.SeleniumException: XHR ERROR: URL = http://localhost:8080/pims Response_Code = 403 Error_Message = Forbidden at com.thoughtworks.selenium.HttpCommandProcessor.throwAssertionFailureExceptionOrError(HttpCommandProcessor.java:97) at com.thoughtworks.selenium.HttpCommandProcessor.doCommand(HttpCommandProcessor.java:91) at com.thoughtworks.selenium.DefaultSelenium.open(DefaultSelenium.java:335) at org.pimslims.seleniumtest.FirstTest.testNew(FirstTest.java:32) ... I can do a similar test on http:/ /localhost:8080 (space between the slashes here because SO thinks I'm spamming) and it's fine - I can make IE open that Tomcat default page and click a link. It's only if I try to open my application at http:/ /localhost:8080/pims that I see this error - and only in IE. I can open that URL in IE by typing it into the address bar. I was convinced that there's some setting in IE that's causing this, but I've tried everything I can think of. http:/ /localhost:8080 is in my Trusted Sites, and I've turned the security for that zone down to the minimum, allowed anything that looks related to popups, etc. If I try adding http:/ /localhost:8080/pims/ to Trusted Sites, IE says it's already there. I've also messed around with proxy settings, to no avail, but may have missed something obvious. I've tried starting the test with *iexplore, *iehta, and *iexploreproxy - all behave the same. Is there something I've missed? For reference, here is my test case - this works as is, in Firefox, opening the PIMS application's index page and clicking a link: public class FirstTest extends SeleneseTestCase { @Override public void setUp() throws Exception { this.setUp("http://localhost:8080/", "*firefox"); } public void testNew() throws Exception { final Selenium s = this.selenium; s.open("/pims"); s.click("logInOutLink"); s.waitForPageToLoad("30000"); } } Any help is greatly appreciated!

    Read the article

  • GZipStream not reading the whole file

    - by Ed
    I have some code that downloads gzipped files, and decompresses them. The problem is, I can't get it to decompress the whole file, it only reads the first 4096 bytes and then about 500 more. Byte[] buffer = new Byte[4096]; int count = 0; FileStream fileInput = new FileStream("input.gzip", FileMode.Open, FileAccess.Read, FileShare.Read); FileStream fileOutput = new FileStream("output.dat", FileMode.Create, FileAccess.Write, FileShare.None); GZipStream gzipStream = new GZipStream(fileInput, CompressionMode.Decompress, true); // Read from gzip steam while ((count = gzipStream.Read(buffer, 0, buffer.Length)) > 0) { // Write to output file fileOutput.Write(buffer, 0, count); } // Close the streams ... I've checked the downloaded file; it's 13MB when compressed, and contains one XML file. I've manually decompressed the XML file, and the content is all there. But when I do it with this code, it only outputs the very beginning of the XML file. Anyone have any ideas why this might be happening?

    Read the article

  • Django conditional template inheritance

    - by Ed
    I have template that displays object elements with hyperlinks to other parts of my site. I have another function that displays past versions of the same object. In this display, I don't want the hyperlinks. I'm under the assumption that I can't dynamically switch off the hyperlinks, so I've included both versions in the same template. I use an if statement to either display the hyperlinked version or the plain text version. I prefer to keep them in the same template because if I need to change the format of one, it will be easy to apply it to the other right there. The template extends framework.html. Framework has a breadcrumb system and it extends base.html. Base has a simple top menu system. So here's my dilemma. When viewing the standard hyperlink data, I want to see the top menu and the breadcrumbs. But when viewing the past version plain text data, I only want the data, no menu, no breadcrumbs. I'm unsure if this is possible given my current design. I tried having framework inherit the primary template so that I could choose to call either framework (and display the breadcrumbs), or the template itself, thus skipping the breadcrumbs, but I want framework.html available for other templates as well. If framework.html extends a specific template, I lose the ability to display it in other templates. I tried writing an if statement that would display a the top_menu block and the nav_menu block from base.html and framework.html respectively. This would overwrite their blocks and allow me to turn off those elements conditional on the if. Unfortunately, it doesn't appear to be conditional; if the block elements are in the template at all, surrounded by an if or not, I lose the menus. I thought about using {% include %} to pick up the breadcrumbs and a split out top menu. In that case though, I'll have to include it all the time. No more inheritance. Is this the best option given my requirement?

    Read the article

  • LinkageError thrown when attempting to pass instance of class between 2 eclipse plugins

    - by Ed
    I have found many people with simliar issues but no soultions...basically I have two eclipse plug-ins that both in ther class path rely on the same jar. The UI plug-in replies on the Driver plug-in (implementing a custom ODA driver and UI for it). Both rely on a jar containing some other classes of mine and is called plugin-dto.jar When the UI plug-in calls a method on one of the classes in the Driver plug-in that returns an object whose class is found in the plugin-dto jar I get the error: java.lang.LinkageError: Class com/test/reporting/NrDsDriverProvider violates loader constraints at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:620) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.defineClass(DefaultClassLoader.java:183) at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.defineClass(ClasspathManager.java:576) at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findClassImpl(ClasspathManager.java:546) at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClassImpl(ClasspathManager.java:477) at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass_LockClassLoader(ClasspathManager.java:465) at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:445) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:211) at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:381) at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:457) at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:410) at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:398) at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:105) at java.lang.ClassLoader.loadClass(ClassLoader.java:251) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319) Any ideas how I get around this issue? Thanks in advance.

    Read the article

  • Django resizing an image pre save using PIL

    - by Ed
    Ugh, I hate having to ask a question on such a common feature, but. . . I'm using an ImageField in a form to upload a photo to S3. I want to resize the image before it is uploaded to S3. I'm trying to use PIL to test the dimensions and resize if necessary. The Image.open() part is throwing me though. It wants a filepath, and the ImageField from the form is only returning the actual file and filename. How can I resize the image before it's saved to S3? Before we get to this point, I'm not using sorl because I believe sorl is compatible with models using ImageFields. But the model associated with the saved S3 images holds just the url of the image on S3 as opposed to using ImageFields.

    Read the article

  • What image format is fastest for BlackBerry?

    - by Ed Marty
    I'm trying to load some images using Bitmap.getBitmapResource(), but it takes about 2 or 3 seconds per image to load. I'm testing on the Storm, specifically. The odd thing is, when I install OS 5.0, the loading goes in a snap, no delay at all. Should I be looking at the format used? Or where the files are stored? I've tried both 24- and 8-bit PNGs, with transparency. The files are stored in a subdirectory in the COD, so getBitmapResource is passed a path, like "images/img1.png" instead of just "img1.png". Is any of this making things slower?

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >