Search Results

Search found 6941 results on 278 pages for 'drupal views'.

Page 62/278 | < Previous Page | 58 59 60 61 62 63 64 65 66 67 68 69  | Next Page >

  • Background color remaining when switching views

    - by Guy
    Hi Guys. I have a UIViewController named equationVC who's user interface is being programmatically created from another NSObject class called equationCon. Upon loading equationVC, a method called chooseInterface is called from the equationCon class. I have a global variable (globalVar) that points to a user defined string. chooseInterface finds a method in the equationCon class that matches the string globalVar points to. In this case, let's say that globalVar points to a string that is called "methodThatMatches." In methodThatMatches, another view controller needs to show the results of what methodThatMatches did. methodThatMatches creates a new equationVC that calls upon methodThatMatches2. As a test, each method changes the color of the background. When the application starts up, I get a purple background, but as soon as I hit backwards I get another purple screen, which should be yellow. I do not think that I am release the view properly. Can anyone help? -(void)chooseInterface { NSString* equationTemp = [globalVar stringByReplacingOccurrencesOfString:@" " withString:@""]; equationTemp = [equationTemp stringByReplacingOccurrencesOfString:@"'" withString:@""]; SEL equationName = NSSelectorFromString(equationTemp); NSLog(@"selector! %@",NSStringFromSelector(equationName)); if([self respondsToSelector:equationName]){ [self performSelector:equationName]; } } -(void)methodThatMatches{ self.equationVC.view.backgroundColor = [UIColor yellowColor]; [setGlobalVar:@"methodThatMatches2"]; EquationVC* temp = [[EquationVC alloc] init]; [[self.equationVC navigationController] pushViewController:temp animated:YES ]; [temp release]; } -(void)methodThatmatches2{ self.equationVC.view.backgroundColor = [UIColor purpleColor]; }

    Read the article

  • Rails Mikel Mail Gem How to use Views

    - by Victor Martins
    I'm trying to use mikel gem mail on my 2.3.5 Rails App http://github.com/mikel/mail I have it working like this. I've made a MailComHelper, made a method like this : def self.welcome(user,password) @user = user m = Mail.new m.from = '[email protected]' m.to = @user.email m.subject = 'welcome' m.body = 'The body' m.delivery_method :sendmail m.deliver! end And it works, I receive the mail. But I wish I could use the old way of calling a view ( html.erb ) file and send that code has the body. I've read the documentation but haven't found a way to do it. Has anyone found a way to do it?

    Read the article

  • uniimageview not updating after views tranistion

    - by Fabio Ricci
    Hi I have one main view where I display an image, in the method viewDidLoad: ballRect = CGRectMake(posBallX, 144, 32.0f, 32.0f); theBall = [[UIImageView alloc] initWithFrame:ballRect]; [theBall setImage:[UIImage imageNamed:@"ball.png"]]; [self.view addSubview:theBall]; [laPalla release]; Obviously, the value of posBallX is defined and then update via a custom method call many times in the same class. theBall.frame = CGRectMake(posBallX, 144, 32, 32); Everything works, but when I go to another view with [self presentModalViewController:viewTwo animated:YES]; and come back with [self presentModalViewController:viewOne animated:YES]; the image is displayed correctly after the method viewDidLoad is called (I retrieve the values with NSUserDefaults) but no more in the second method. In the NSLog I can even see the new posBallX updating correctly, but the Image is simply no more shown... The same happens with a Label as well, which should print the value of posBallX. So, things are just not working if I come back to the viewOne from the viewTwo... Any idea??????? Thanks so much!

    Read the article

  • ViewModel Views relation/link/syncroniztion

    - by mehran
    Third try to describing problem: Try 1: Sunchronizing view model and view Try2: WPF ViewModel not active presenter Try3: I have some class for view models: public class Node : INotifyPropertyChanged { Guid NodeId { get; set; } public string Name { get; set; } } public class Connection: INotifyPropertyChanged { public Node StartNode { get; set; } public Node EndNode { get; set; } } public class SettingsPackModel { public List<Node> Nodes { get; private set; } public List<Connection> Connections { get; private set; } } I also have some templates to displays these models: <DataTemplate DataType="{x:Type vm:Node}">…</DataTemplate> <DataTemplate DataType="{x:Type vm:Connection}"> <my:ConnectionElment StartNodeElment="???" EndNodeElment="???"> </my:ConnectionElment> <DataTemplate> But the problem is that DataTemplate for Connection need reference ot two element of type UIElement , how can I pass these two, how can I fill ??? in above expression?

    Read the article

  • presenting modal views in a popover

    - by sengbsd
    Hi, Im trying to load a modal view from a view controller that is displayed in a popover. The modal view loads but the problem is that it transitions into the main view and not within the popover. Is it something Im missing? I thought simply initiating it from a vc within a popover would present the modal view within the same popover... The code is nothing special as bellow: - (IBAction)myButton{ ModalVC *controller = [[ModalVC alloc] initWithNibName:@"ModalVC" bundle:nil]; [self presentModalViewController:controller animated:YES]; [controller release]; }

    Read the article

  • Add programmatically clickable Button with custom Views layouted in InterfaceBuilder

    - by allisone
    I have a UIScrollView. In there I add buttons programmatically. Right now I just use UIButton and set one title. But I need to have an UIImage View in there, that will change upon certain events, Text that will change too etc. and I would like to style that in Interface Builder, but I can't figure out how to do this. Which class should I extend, and what kind of xib should I create and what in there, so that in the end I can make the right connections and so that I can listen for UIControlEventTouchDown of that Button.

    Read the article

  • How to partially update views in an app widget without rebuilding all the RemoteViews

    - by Gianni Costanzi
    I'm implementing an app widget and I'd like to be able to change the property of a single view in the widget layout, without rebuilding all the RemoteViews from scratch, which involves loading XML etc and which is not necessary in some circumstances.. Is there a way to say "update property X on view identified by a specific ID in the current widget layout"? I've seen that there is a partiallyUpdateAppWidget method in the AppWidgetManager class but I can't understand nor if it is meant for this purpose neither how it must be used.. Can you help me or point me to a useful link or example?

    Read the article

  • MVP - asp.net - passing information via views - confused

    - by ekynox
    Hi, I've just started to play around with MVP in asp.net. One thing I quite cant figure out is how do I pass information, i.e. an integer variable from one view(webform) to another. Let's I have a customerlistView which is mapped to a customerlist.aspx page. From it I select a customer and it's record id. Say I want to display the customer's details in another view (i.e customerDetailView, customerdetail.aspx). How do I achieve that ? Does that mean customerlistView would call the presenter of the customerdetail and cause a page redirect ? Any ideas ? thanks

    Read the article

  • iPhone - adding views and landscape orientation

    - by Franz
    I got a problem with Cocoa touch and landscape orientation. I instantiate my view from a .xib; i added in my view controller - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { return interfaceOrientation == UIInterfaceOrientationLandscapeRight; } to only allow landscape orientation. This works find for the first view i add.. if I add a second view however it is rotated again like the landscape view is shown in portrait mode (rotated 90 degree counterclockwise). I really don't know what is going on and can't find a workaround. I even tried to get behind what is happening just adding my view twice: MainMenuViewController* controller = [[MainMenuViewController alloc] initWithNibName:@"MainMenu" bundle:nil]; [window addSubview: controller.view]; MainMenuViewController* controller2 = [[MainMenuViewController alloc] initWithNibName:@"MainMenu" bundle:nil]; [window addSubview: controller2.view]; [window makeKeyAndVisible]; The view of controller is displayed correctly, while the view of controller2 is rotated by 90 degrees. Does anyone have an idea how this can happen? Thanks for your help.

    Read the article

  • Detached views in eclipse on linux

    - by Nils Otto
    Hi, When i detach wiews in eclipse on ubuntu, eg package explorer, it shows up as a separate window in ubuntu (Eclipse ends up taking up 4 windows, and that makes alt-tabbing through my open programs a pain) Is there a way to fix this so Eclipse only show up as one window in ubuntu no matter how many vews are detached?

    Read the article

  • Resizing Tab Bar Controller Views (iPhone dev)

    - by damiandawber
    Hello, I have an application set up where the window contains a tab bar controller and one of the tabs loads a NIB called 'ShowCaseView.xib': this file is owned by a custom ShowcaseViewController class. In the ShowcaseViewcontroller class I have added a UIScrollView object, like so: imageScrollView = [[UIScrollView alloc] initWithFrame:[[self view] bounds]]; [[self view] addSubview:imageScrollView]; The issue I am having is that this UIScrollView object extends beneath my tab bar controller. So I have had to reduce its insets manually: #define TAB_BAR_HEIGHT 48 . . UIEdgeInsets edgeInsets = UIEdgeInsetsMake(0, 0, TAB_BAR_HEIGHT, 0); [imageScrollView setScrollIndicatorInsets:edgeInsets]; So, Is it common to have to manually deduct the tab bar height from a view (whether this be by reducing the size of subviews or the View NIB in inspector)? Is there a way that I can tell a NIB's view loaded from a tab bar to resize itself automatically to NOT sit behind the tab bar? Cheers

    Read the article

  • iPhone OS: Rotate just the button images, not the views

    - by Jongsma
    Hi, I am developing an iPad application which is basically a big drawing canvas with a couple of button at the side. (Doesn't sound very original, does it? :P) No matter how the user holds the device, the canvas should remain in place and should not be rotated. The simplest way to achieve this would be to support just one orientation. However, I would like the images on the buttons to rotate (like in the iPhone camera app) when the device is rotated. UIPopoverControllers should also use the users current orientation (and not appear sideways). What is the best way to achieve this? (I figured I could rotate the canvas back into place with an affineTransform, but I don't think it is ideal.) Thanks in advance!

    Read the article

  • Partial views in asp.net mvc

    - by Renu123
    i am using partial view for my project but my problem is that my links are on right side of masterpage and when i clicked on particular link the view should displayed on left side on contentplace holder of master page. but right now its showing exactly below so my whole disgne is distrubed. so please if anyone know the solution tell me. thanks

    Read the article

  • close the soft key pad when i click on other views in android

    - by sairam333
    I want to open the soft key pad when we click on or focus on edit text.Suppose in my application I have one Edittext view and image view at that time when i click on image view automatically the soft key pad will be closed.when i click on or focus on edittext at that time only Soft keypad will be opened what can i do? give me some suggestions.Thanks in advance

    Read the article

  • Using the same code in different (partial) views

    - by Danny Chen
    Maybe this question is quite simple because I'm new to MVC2. I have a simple demo MVC project. (1) A weak-typed view: Index.aspx <% Html.RenderPartial("ArticalList", ViewData["AllArticals"] as List<Artical>); %> (2) A strong-typed partical view: ArticalList.ascx <%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<List<Artical>>" %> <% foreach (Artical a in Model) { %> <%= Html.ActionLink(a.Title, "About", new { id = a.ID })%><br /> <%} %> (3) Here is the HomeController.cs public ActionResult Index() { ViewData["AllArticals"] = Artical.GetArticals(); return View(); } public ActionResult ArticalList() { return PartialView(Artical.GetArticals()); } Sorry I'm using a Web-Form "angle", because if I'm using a Web-Form, when I visit Index.aspx, rendering ArticalList.ascx will call public ActionResult ArticalList(). But here I need to write Artical.GetArticals() twice in two actions. How can I put them in one?

    Read the article

  • Only show non blank attributes for a model in views in Rails

    - by Senthil
    Say I've a user model and there are bunch of user info, like email, birthdate, location, telephone number etc. What's the simplest way of hiding the attributes that are blank? I've doing something like <% if blog.title.empty? -%> <p>Body: <%=h blog.body %></p> <p>Comments: <%=h blog.comments %></p> <% elsif blog.body.empty? %> <p>Title: <%=h blog.title %></p> <p>Comments: <%=h blog.comments %></p> <% else -%> <p>Title: <%=h blog.title %></p> <p>Body: <%=h blog.body %></p> <% end -%> Clearly that is one ugly child. Other than using partials to render, is there a trick to only show non blank fields? I've been trying to write a helpher method to make the view cleaner, but that's even more ugly. Any help is appreciated.

    Read the article

  • Android views' borders issue on some devices

    - by htafoya
    Hi there, Some users have been reporting border alignment issues on some android components such as the alert popup or the editTexts. This is happening on the Samsung Galaxy Apollo (200x400) and the HTC Pro Touch (480x640) devices. I cannot replicate that because i don't own those devices and in the Samsung Galaxy S and emulator everything looks just right. I think that the problem is the dpi or resolution of the device (because the edittext background is a single .9.png so image should look ok); however I am not sure if the supports-screens tag is the solution. Also, application was developed using Api 3 (v1.5) and supports-screens was not yet supported, nor the screen-size resource qualifier. The style used for the alerts and editText is the phone default. Could the problem be something related with the theme applied to the phone by the user? Thanks in advance!, I show some images given to me showing the problem: //EDIT: I can't post images because i am new; i will put a link: borders issue link img

    Read the article

  • UINavigationController crashes after pushing 3 views onto stack

    - by joec
    I have a navigation controller, which has the following structure: Category Item Item Detail I can choose a category, and then choose an item to see its details. I can do this twice, i.e. go Back to the list of items and select another item. If i try this a third time, the app crashes, I get objc_msgSend in stack but thats all. But, instead of choosing another item, i go to the list of categories, and choose a different category, I can select two items in that category, before it crashes also. What would be causing this? Thanks

    Read the article

  • Forbid GridView to load all views at once

    - by efpies
    I have about 700 items to display in the grid view. On a Samsung Galaxy Tab 10.1 this is not a problem: it has enough memory. On a HTC Explorer the heap is overflown. So I want to load data dynamically regarding current scroll position (N rows for screen + 5 rows as a tail). And I want to show a scrollbar which represents the position in total rows. But I don't want to draw items that I don't see. In other words, I want to create something similar to UITableView in iOS. How can I do this?

    Read the article

  • iPhone Input with Stacked Views

    - by Forrest
    Hi, I've got a situation in an iphone application where buttons are not receiving input as I expect. Here's the setup: ViewMain - The main view full of various images and labels ViewOverlay - A HUD like overlay view with two UIButton objects. To create my scene I do the following: viewController.view = ViewMain [ViewMain addsubview:ViewOverlay] This view renders as expected, with ViewOverlay correctly rendered ontop of ViewMain. However the two buttons found inside ViewOverlay do not receive touch events and can not be pressed. Tapping them does nothing at all. I very well may be going about this in the entirely wrong direction. Any ideas?

    Read the article

  • Transition between many Views in ViewFlipper ?

    - by user164589
    Hi guys, I am using "ViewFlipper" for my application. This ViewFlipper includes 5 layouts. I am trying make it that can be changed from current layout to any layout. In other words, it can be changed Layout#1 - Layout#5 or Layout#4 - Layout#1 ..etc. How to make it ? I used showNext() and showPrevious(). It is not better idea for my case. Can I use ViewSwither instead of this case ? Please advice. Can you give example code related this issue ? Thanks in advance.

    Read the article

  • Limit number of views per day in Django

    - by ariddell
    Is there an easy way to limit the number of times a view can be accessed by a given IP address per day/week? A simplified version of the technique used by some booksellers to limit the number of pages of a book you can preview? There's only one view that this limit need apply to--i.e. it's not a general limit--and it would be nice if I could just have a variable overlimit in the template context. The solution need not be terribly robust, but limiting by IP address seemed like a better idea than using a cookie. I've looked into the session middleware but it doesn't make any references to tracking IP addresses as far as I can tell. Has anyone encountered this problem?

    Read the article

  • Tab-Bar not hiding on all views

    - by Sheehan Alam
    I have a tab-bar controller that loads a RootView. The RootView has 4 buttons that will load a UITableView I don't want my tab-bar to be visible in the RootView so I added the following code: -(void)viewDidLoad{ self.hidesBottomBarWhenPushed = YES; } When I initially load the app the tab-bar doesn't appear, but when I click on a button, and go back to the RootView the tab-bar still appears. I have tried placing this code in viewWillAppear and other application lifecycle methods but no luck.

    Read the article

< Previous Page | 58 59 60 61 62 63 64 65 66 67 68 69  | Next Page >