Search Results

Search found 4447 results on 178 pages for 'visible'.

Page 1/178 | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Making a Label Visible/Not Visible in Delphi

    - by Hendriksen123
    I would like a button to change a label between being visible and not visible when clicked. I Tried the following code, but it doesnt work: Var: Hidden : Boolean; Begin If Hidden = True Then Begin Label6.Visible := True; Hidden := False; End; If Hidden = False Then Begin Label6.Visible := False; Hidden := True; End; It compiles, but doesn't work!

    Read the article

  • Flash "visible" issue

    - by justkevin
    I'm writing a tool in Flex that lets me design composite sprites using layered bitmaps and then "bake" them into a low overhead single bitmapData. I've discovered a strange behavior I can't explain: toggling the "visible" property of my layers works twice for each layer (i.e., I can turn it off, then on again) and then never again for that layer-- the layer stays visible from that point on. If I override "set visible" on the layer as such: override public function set visible(value:Boolean):void { if(value == false) this.alpha = 0; else {this.alpha = 1;} } The problem goes away and I can toggle "visibility" as much as I want. Any ideas what might be causing this? Edit: Here is the code that makes the call: private function onVisibleChange():void { _layer.visible = layerVisible.selected; changed(); } The changed() method "bakes" the bitmap: public function getBaked():BitmapData { var w:int = _composite.width + (_atmosphereOuterBlur * 2); var h:int = _composite.height + (_atmosphereOuterBlur * 2); var bmpData:BitmapData = new BitmapData(w,h,true,0x00000000); var matrix:Matrix = new Matrix(); var bounds:Rectangle = this.getBounds(this); matrix.translate(w/2,h/2); bmpData.draw(this,matrix,null,null,new Rectangle(0,0,w,h),true); return bmpData; } Incidentally, while the layer is still visible, using the Flex debugger I can verify that the layer's visible value is "false".

    Read the article

  • jQuery detect visible but hidden elements

    - by IP
    This seems like it should be fairly easy - but I can't find the right selector for it According to the docs (http://api.jquery.com/hidden-selector/ and http://api.jquery.com/visible-selector/)... Elements can be considered hidden for several reasons: An ancestor element is hidden, so the element is not shown on the page. What I want to detect is "this element is visible, but is contained in a hidden parent". Ie, if I made the parent visible, this element would also be visible.

    Read the article

  • ajax tabcontainer with button postback problem

    - by yousof
    I have a dropdownlist in my web page and two command buttons and a tabcontainer. The tabcontainer does not appear after the load of page according to my code. Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load If Not IsPostBack Then TabContainer1.Visible = False If CtvAct.GetRecords("Fill_RequestTypeTb") = True Then ReqTypeCmbo.DataSource = CtvAct.MainDataset.Tables("tbOLRequestType").DefaultView ReqTypeCmbo.DataTextField = "RequestTypeName" ReqTypeCmbo.DataValueField = "RequestTypeId" ReqTypeCmbo.DataBind() Dim itm As New ListItem itm.Text = "-- ??? ??? ????? --" itm.Value = "-1" itm.Selected = True ReqTypeCmbo.Items.Insert(0, itm) ReqTypeCmbo.SelectedIndex = 0 End If End If End Sub Protected Sub PrntCmd_Click(ByVal sender As Object, ByVal e As EventArgs) Handles PrntCmd.Click TextBox6.Text = "gggg" End Sub Protected Sub ReqTypeCmbo_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs) Handles ReqTypeCmbo.SelectedIndexChanged If ReqTypeCmbo.SelectedItem.Text = "????" Then TabContainer1.Visible = True TabContainer1.ActiveTabIndex = 0 OwnerDataPnl.Enabled = True AttornyDataPnl.Enabled = True BaseDataPnl.Enabled = True RenwDataPnl.Visible = False NewOwnerDataPnl0.Visible = False AddActivtyPnl.Visible = False SubstitPnl.Visible = False FinishLicePnl.Visible = False CancelActivityPnl.Visible = False LocTransPnl.Visible = False ' Panel1.Visible = False '?????? ?????? ??????? ???????? REstOfficeAddrTxt.Enabled = True REstOffIdeIssuedPlaceTxt.Enabled = True REstOffIdentityNameTxt.Enabled = True REstOffIdentityNumberTxt.Enabled = True REstOffIdentityStartDateTxt.Enabled = True REstOffMobileTxt.Enabled = True REstOffNameTxt.Enabled = True REstOffPhoneTxt.Enabled = True OwnerShipNumberTxt.Enabled = True OwnerShipDateTxt.Enabled = True OwnerShipIssuedPlaceTxt.Enabled = True SerailTxt.Enabled = True RequestIdTxt.Enabled = True RequestDateTxt.Enabled = True RenwDataPnl.Visible = True '''' If CtvAct.GetRecords("Fill_NationalityTb") = True Then OwnrNationCmbo.DataSource = CtvAct.MainDataset.Tables("tbOLNationality").DefaultView OwnrNationCmbo.DataTextField = "NationName" OwnrNationCmbo.DataValueField = "NationId" OwnrNationCmbo.DataBind() Dim itm As New ListItem itm.Text = "-- ??? ??????? --" itm.Value = "-1" itm.Selected = True OwnrNationCmbo.Items.Insert(0, itm) OwnrNationCmbo.SelectedIndex = 0 End If If CtvAct.GetRecords("Fill_ActivityTb") = True Then AcivityCombo.DataSource = CtvAct.MainDataset.Tables("tbOLActivity").DefaultView AcivityCombo.DataTextField = "ActivityName" AcivityCombo.DataValueField = "ActivityId" AcivityCombo.DataBind() AcivityCombo.SelectedIndex = -1 Dim itm As New ListItem itm.Text = "-- ??? ?????? --" itm.Value = "-1" itm.Selected = True AcivityCombo.Items.Insert(0, itm) AcivityCombo.SelectedIndex = 0 End If 'If CtvAct.GetRecords("Fill_ActivityTb") = True Then ' DropDownList2.DataSource = CtvAct.MainDataset.Tables("tbOLActivity").DefaultView ' DropDownList2.DataTextField = "ActivityName" ' DropDownList2.DataValueField = "ActivityId" ' DropDownList2.DataBind() 'AcivityCombo.Visible = True ' LbCon.Text = CtvAct.Prt 'End If AttronayNationCmbo.SelectedIndex = -1 If CtvAct.GetRecords("Fill_NationalityTb") = True Then AttronayNationCmbo.DataSource = CtvAct.MainDataset.Tables("tbOLNationality").DefaultView AttronayNationCmbo.DataTextField = "NationName" AttronayNationCmbo.DataValueField = "NationId" AttronayNationCmbo.DataBind() Dim itm As New ListItem itm.Text = "-- ??? ??????? --" itm.Value = "-1" itm.Selected = True AttronayNationCmbo.Items.Insert(0, itm) AttronayNationCmbo.SelectedIndex = 0 ' LbCon.Text = CtvAct.Prt End If If CtvAct.GetRecords("Fill_LocationTb") = True Then LocationIdCmbo.DataSource = CtvAct.MainDataset.Tables("tbOLLocation").DefaultView LocationIdCmbo.DataTextField = "LocationName" LocationIdCmbo.DataValueField = "LocationId" LocationIdCmbo.DataBind() Dim itm As New ListItem itm.Text = "-- ??? ?????? --" itm.Value = "-1" itm.Selected = True LocationIdCmbo.Items.Insert(0, itm) LocationIdCmbo.SelectedIndex = 0 ' LbCon.Text = CtvAct.Prt End If '''''''''''''''''''''''''''''''' con = New SqlConnection(CtvAct.Connection_String()) CmdActivty = con.CreateCommand CmdActivty.CommandText = "SELECT ActivityId FROM tbOLStoreActivty" DaActivity.SelectCommand = CmdActivty DaActivity.Fill(DsActivity, "tbOLStoreActivty") ActivityGV.DataSource = DaActivity ActivityGV.DataMember = "tbOLStoreActivty" AcivityCombo.DataSource = ds.Tables(0) AcivityCombo.DataTextField = "ename" AcivityCombo.DataValueField = "eid" AcivityCombo.DataBind() ''''''''''''''''''''''''''''' LbCon.Text = CtvAct.Prt ElseIf ReqTypeCmbo.SelectedItem.Text = "?????" Then TabContainer1.Visible = True TabContainer1.ActiveTabIndex = 1 OwnerDataPnl.Enabled = False AttornyDataPnl.Enabled = False BaseDataPnl.Enabled = True AddActivtyPnl.Visible = False SubstitPnl.Visible = False FinishLicePnl.Visible = False RenwDataPnl.Visible = True AddActivtyPnl.Visible = False NewOwnerDataPnl0.Visible = False CancelActivityPnl.Visible = False LocTransPnl.Visible = False '?????? ?????? ??????? ???????? REstOfficeAddrTxt.Enabled = False REstOffIdeIssuedPlaceTxt.Enabled = False REstOffIdentityNameTxt.Enabled = False REstOffIdentityNumberTxt.Enabled = False REstOffIdentityStartDateTxt.Enabled = False REstOffMobileTxt.Enabled = False REstOffNameTxt.Enabled = False REstOffPhoneTxt.Enabled = False OwnerShipNumberTxt.Enabled = False OwnerShipDateTxt.Enabled = False OwnerShipIssuedPlaceTxt.Enabled = False SerailTxt.Enabled = True RequestIdTxt.Enabled = True RequestDateTxt.Enabled = True ''''''''' ElseIf ReqTypeCmbo.SelectedItem.Text = "??? ?????" Then TabContainer1.Visible = True TabContainer1.ActiveTabIndex = 1 OwnerDataPnl.Enabled = False AttornyDataPnl.Enabled = False BaseDataPnl.Enabled = False RenwDataPnl.Visible = False NewOwnerDataPnl0.Visible = True AddActivtyPnl.Visible = False SubstitPnl.Visible = False FinishLicePnl.Visible = False CancelActivityPnl.Visible = False LocTransPnl.Visible = False ElseIf ReqTypeCmbo.SelectedItem.Text = "????? ????" Then TabContainer1.Visible = True TabContainer1.ActiveTabIndex = 1 OwnerDataPnl.Enabled = False AttornyDataPnl.Enabled = False BaseDataPnl.Enabled = False RenwDataPnl.Visible = False NewOwnerDataPnl0.Visible = False AddActivtyPnl.Visible = False SubstitPnl.Visible = False FinishLicePnl.Visible = False CancelActivityPnl.Visible = True LocTransPnl.Visible = False ElseIf ReqTypeCmbo.SelectedItem.Text = "????? ????" Then TabContainer1.Visible = True TabContainer1.ActiveTabIndex = 1 OwnerDataPnl.Enabled = False AttornyDataPnl.Enabled = False BaseDataPnl.Enabled = False RenwDataPnl.Visible = False NewOwnerDataPnl0.Visible = False AddActivtyPnl.Visible = False SubstitPnl.Visible = False FinishLicePnl.Visible = True LocTransPnl.Visible = False ElseIf ReqTypeCmbo.SelectedItem.Text = "??? ???? / ????" Then TabContainer1.Visible = True TabContainer1.ActiveTabIndex = 1 OwnerDataPnl.Enabled = False AttornyDataPnl.Enabled = False BaseDataPnl.Enabled = False RenwDataPnl.Visible = False NewOwnerDataPnl0.Visible = False AddActivtyPnl.Visible = False SubstitPnl.Visible = True FinishLicePnl.Visible = False LocTransPnl.Visible = False ElseIf ReqTypeCmbo.SelectedItem.Text = "??? ????" Then TabContainer1.Visible = True TabContainer1.ActiveTabIndex = 0 OwnerDataPnl.Enabled = True AttornyDataPnl.Enabled = True BaseDataPnl.Enabled = True RenwDataPnl.Visible = False NewOwnerDataPnl0.Visible = False AddActivtyPnl.Visible = False SubstitPnl.Visible = False FinishLicePnl.Visible = False CancelActivityPnl.Visible = False LocTransPnl.Visible = True End If End Sub If I press any button after page load the button work very selecting any item from dropdownlist make the tabcontainer appear but after the tabcontainer appear, the buttons does not work (postback) how can I solve these problems

    Read the article

  • Responsive Inline Elements with Twitter Bootstrap

    - by MightyZot
    Originally posted on: http://geekswithblogs.net/MightyZot/archive/2013/11/12/responsive-inline-elements-with-twitter-bootstrap.aspxTwitter Boostrap is a responsive css platform created by some dudes affiliated with Twitter and since supported and maintained by an open source following. I absolutely love the new version of this css toolkit. They rebuilt it with a mobile first strategy and it’s very easy to layout pages once you get the hang of it. Using a css / javascript framework like bootstrap is certainly much easier than coding your layout by hand. And, you get a “leg up” when it comes to adding responsive features to your site. Bootstrap includes column layout classes that let you specify size and placement based upon the viewport width. In addition, there are a handful of responsive helpers to hide and show content based upon the user’s device size. Most notably, the visible-xs, visible-sm, visible-md, and visible-lg classes let you show content for devices corresponding to those sizes (they are listed in the bootstrap docs.) hidden-xs, hidden-sm, hidden-md, and hidden-lg let you hide content for devices with those respective sizes. These helpers work great for showing and hiding block elements. Unfortunately, there isn’t a provision yet in Twitter Bootstrap (as of the time of this writing) for inline elements. We are using the navbar classes to create a navigation bar at the top of our website, www.crowdit.com. When you shrink the width of the screen to tablet or phone size, the tools in the navbar are turned into a drop down menu, and a button appears on the right side of the navbar. This is great! But, we wanted different content to display based upon whether the items were on the navbar versus when they were in the dropdown menu. The visible-?? and hidden-?? classes make this easy for images and block elements. In our case, we wanted our anchors to show different text depending upon whether they’re in the navbar, or in the dropdown. span is inherently inline and it can be a block element. My first approach was to create two anchors for each options, one set visible when the navbar is on a desktop or laptop with a wide display and another set visible when the elements converted to a dropdown menu. That works fine with the visible-?? and hidden-?? classes, but it just doesn’t seem that clean to me. I put up with that for about a week…last night I created the following classes to augment the block-based classes provided by bootstrap. .cdt-hidden-xs, .cdt-hidden-sm, .cdt-hidden-md, .cdt-hidden-lg {     display: inline !important; } @media (max-width:767px) {     .cdt-hidden-xs, .cdt-hidden-sm.cdt-hidden-xs, .cdt-hidden-md.cdt-hidden-xs, .cdt-hidden-lg.cdt-hidden-xs {         display: none !important;     } } @media (min-width:768px) and (max-width:991px) {     .cdt-hidden-xs.cdt-hidden-sm, .cdt-hidden-sm, .cdt-hidden-md.cdt-hidden-sm, .cdt-hidden-lg.cdt-hidden-sm {         display: none !important;     } } @media (min-width:992px) and (max-width:1199px) {     .cdt-hidden-xs.cdt-hidden-md, .cdt-hidden-sm.cdt-hidden-md, .cdt-hidden-md, .cdt-hidden-lg.cdt-hidden-md {         display: none !important;     } } @media (min-width:1200px) {     .cdt-hidden-xs.cdt-hidden-lg, .cdt-hidden-sm.cdt-hidden-lg, .cdt-hidden-md.cdt-hidden-lg, .cdt-hidden-lg {         display: none !important;     } } .cdt-visible-xs, .cdt-visible-sm, .cdt-visible-md, .cdt-visible-lg {     display: none !important; } @media (max-width:767px) {     .cdt-visible-xs, .cdt-visible-sm.cdt-visible-xs, .cdt-visible-md.cdt-visible-xs, .cdt-visible-lg.cdt-visible-xs {         display: inline !important;     } } @media (min-width:768px) and (max-width:991px) {     .cdt-visible-xs.cdt-visible-sm, .cdt-visible-sm, .cdt-visible-md.cdt-visible-sm, .cdt-visible-lg.cdt-visible-sm {         display: inline !important;     } } @media (min-width:992px) and (max-width:1199px) {     .cdt-visible-xs.cdt-visible-md, .cdt-visible-sm.cdt-visible-md, .cdt-visible-md, .cdt-visible-lg.cdt-visible-md {         display: inline !important;     } } @media (min-width:1200px) {     .cdt-visible-xs.cdt-visible-lg, .cdt-visible-sm.cdt-visible-lg, .cdt-visible-md.cdt-visible-lg, .cdt-visible-lg {         display: inline !important;     } } I created these by looking at the example provided by bootstrap and consolidating the styles. “cdt” is just a prefix that I’m using to distinguish these classes from the block-based classes in bootstrap. You are welcome to change the prefix to whatever feels right for you. These classes can be applied to spans in textual content to hide and show text based upon the browser width. Applying the styles is simple… <span class=”cdt-visible-xs”>This text is visible in extra small</span> <span class=”cdt-visible-sm”>This text is visible in small</span> Why would you want to do this? Here are a couple of examples, shown in screen shots. This is the CrowdIt navbar on larger displays. Notice how the text is two line and certain words are capitalized? Now, check this out! Here is a screen shot showing the dropdown menu that’s displayed when the browser window is tablet or phone sized. The markup to make this happen is quite simple…take a look. <li>     <a href="@Url.Action("what-is-crowdit","home")" title="Learn about what CrowdIt can do for your Small Business">         <span class="cdt-hidden-xs">WHAT<br /><small>is CrowdIt?</small></span>         <span class="cdt-visible-xs">What is CrowdIt?</span>     </a> </li> There is a single anchor tag in this example and only the spans change visibility based on browser width. I left them separate for readability and because I wanted to use the small tag; however, you could just as easily hide the “WHAT” and the br tag on small displays and replace them with “What “, consolidating this even further to text containing a single span. <span class=”cdt-hidden-xs”>WHAT<br /></span><span class=”cdt-visible-xs”>What </span>is CrowdIt? You might be a master of css and have a better method of handling this problem. If so, I’d love to hear about your solution…leave me some feedback! You’ll be entered into a drawing for a chance to win an autographed picture of ME! Yay!

    Read the article

  • Performance of jquery visible

    - by Mark Steudel
    I have a bunch of checkboxes on a page, and I only show a subset of those checkboxes at a time. I then perform some action which loops through all of the checkboxes and sees if they are checked or not: e.g. $(".delete_items").click( function() { $('.checkboxes' ).each(function(){ //do stuff } } Then I was thinking, well since the user can never interact with the hidden checkboxes, that adding :visible to checkboxes would speed up the loop e.g. $(".delete_items").click( function() { $('.checkboxes :visible' ).each(function(){ //do stuff } } But I don't know if adding :visible adds more overhead. Any thoughts?

    Read the article

  • Jquery if visible conditional not working

    - by Wade D Ouellet
    Hey, I have a page going here that uses jQuery: http://treethink.com/services What I am trying to do is, if a slide or sub-page is shown in there, change the background colour and colour of the button. To do this I tried saying, if a certain div is shown, the background colour of a certain button changes. However, you can see there that it isn't working properly, it is changing the colour for the web one but not removing the colour change and adding a colour change on a different button when you change pages. Here is the overall code: /* Hide all pages except for web */ $("#services #web-block").show(); $("#services #print-block").hide(); $("#services #branding-block").hide(); /* When a button is clicked, show that page and hide others */ $("#services #web-button").click(function() { $("#services #web-block").show(); $("#services #print-block").hide(); $("#services #branding-block").hide(); }); $("#services #print-button").click(function() { $("#services #print-block").show(); $("#services #web-block").hide(); $("#services #branding-block").hide(); }); $("#services #branding-button").click(function() { $("#services #branding-block").show(); $("#services #web-block").hide(); $("#services #print-block").hide(); }); /* If buttons are active, disable hovering */ if ($('#services #web-block').is(":visible")) { $("#services #web-button").css("background", "#444444"); $("#services #web-button").css("color", "#999999"); } if ($('#services #print-block').is(":visible")) { $("#services #print-button").css("background", "#444444"); $("#services #print-button").css("color", "#999999"); } if ($('#services #branding-block').is(":visible")) { $("#services #branding-button").css("background", "#444444"); $("#services #branding-button").css("color", "#999999"); } Thanks, Wade

    Read the article

  • Nested Linear layout only shows first view after being set from gone to visible in Android

    - by Adam
    Hi guys, I am developing an Android app but I'm still pretty new. I want to have a button, and when you push that button, a few TextViews and Buttons will appear. So I have a main linear layout, and then another linear layout nested inside containing the things I want hidden. I have the nested linear layout set to android:visibility="gone". The problem I am having is that it only shows the first item inside the hidden linear layout instead of all of them. The way I try to make it appear is vgAddView = (ViewGroup)findViewById(R.id.add_details); btnAche.setOnClickListener(new OnClickListener(){ public void onClick(View v){ vgAddView.setVisibility(0); } }); My XML file is this <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" > <Button android:text="@string/but_stomach_ache" android:id="@+id/but_stomach_ache" android:layout_width="fill_parent" android:layout_height="wrap_content"> </Button> <Button android:text="@string/but_food" android:id="@+id/but_food" android:layout_width="fill_parent" android:layout_height="wrap_content"> </Button> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/add_details" android:visibility="gone"> <TextView android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:text="@string/when_happen"> </TextView> <Button android:text="@string/happen_now" android:id="@+id/happen_now" android:layout_width="fill_parent" android:layout_height="wrap_content"> </Button> </LinearLayout> </LinearLayout>

    Read the article

  • Custom HTMLControl derived from HtmlImage control not visible in VS2008 toolbox

    - by Tinvan
    I have a custom control deriving from HtmlImage control which I cant get to show up on toolbox, it says "There are no components in '...\bin\Debug\ImageCustomControl.dll' that can be placed on the toolbox.". Here is the code for the control: namespace ImageCustomControl { public class ImageHtmlControl : HtmlImage { public override void RenderControl(HtmlTextWriter writer) { this.Src = "https://somedomain.com" + this.Src; base.RenderControl(writer); } } } Here is a post back from 2003 that says its not possible, but just wanted to know if it has changed since: http://www.microsoft.com/mspress/books/sampchap/5728d.aspx Thanks in advance.

    Read the article

  • NASA’s can alert you when Space Station is visible from your backyard

    - by Gopinath
    NASA’s International Space Station(ISS) is the third most brightest object visible in the sky after Sun and Moon. If we know exactly when to look up, we will be able to spot Space Station with naked eye and it looks like bright star moving.  On the occasion of 12th anniversary of astronauts living in space station, NASA started a free services dubbed as Spot The Station, that alerts you when Space Station is visible from your backyard. Those who sign up with the free service by providing location details will get an email & text alerts couple of hours in advance so that they can have a glimpse of space station. Here is a sample alert sent to registered users SpotTheStation! Time: Wed Apr 25 7:45 PM, Visible: 4 min, Max Height: 66 degrees, Appears: WSW, Disappears NE. The space station is typically visible right at early morning or evenings when moon is the only one brightest star visible in the sky. The service is available world wide and almost 90 percent of the population on earth would be able to see clearly without using any fancy equipment. Follow the link spotthestation.nasa.gov to register for alerts. Flickr cc image: slideshow bob

    Read the article

  • .NET C# how to loop through some lable to set their attribute

    - by sydney wynn
    How do I do this in a loop. protected void ddlTool_SelectedIndexChanged(object sender, EventArgs e) { lblTool1.Visible = false; txtTool1.Visible = false; lblTool2.Visible = false; txtTool2.Visible = false; lblTool3.Visible = false; txtTool3.Visible = false; lblTool4.Visible = false; txtTool4.Visible = false; lblTool5.Visible = false; if (ddlTool.SelectedValue == "1") { lblTool1.Visible = true; txtTool1.Visible = true; } if (ddlTool.SelectedValue == "2") { lblTool1.Visible = true; txtTool1.Visible = true; lblTool2.Visible = true; txtTool2.Visible = true; } if (ddlTool.SelectedValue == "3") { lblTool1.Visible = true; txtTool1.Visible = true; lblTool2.Visible = true; txtTool2.Visible = true; lblTool3.Visible = true; txtTool3.Visible = true; } if (ddlTool.SelectedValue == "4") { lblTool1.Visible = true; txtTool1.Visible = true; lblTool2.Visible = true; txtTool2.Visible = true; lblTool3.Visible = true; txtTool3.Visible = true; lblTool4.Visible = true; txtTool4.Visible = true; }

    Read the article

  • Android - how update widget often but only when it is visible?

    - by tomash
    I'm going to create widget which needs to update its content every minute (it shows time-related data). However, there is no need to update widget if it is currently invisible, which means: screen is turned off another app is running widget is placed on another (invisible) home screen tab What is the best way to update only visible widget every minute - without waking up device nor doing unnecessary computations? After widget becomes visible, small lag before update is acceptable.

    Read the article

  • How to prevent my C# winforms application from stealing focus when I set the visible properly to tru

    - by Fopedush
    I've got a C# winforms application that runs in the background, listening for hotkeys to be pressed. When a hotkey is pressed, my form makes a brief appearance. The form is always running, but set to hidden until I receive a hotkey event, at which time I set the visible property to true. The code looks like this: void hook_volumeDown(object sender, KeyPressedEventArgs e) { this.Visible = true; } It should be noted that the topmost property of this form is set to true. The really odd part is, after my C# app has stolen focus from another application, it will never do it again. For example: I launch my app, then launch some fullscreep app like Team Fortress 2. Then I press my hotkey. Team Fortress 2 minimizes, and I see my form. Then, however, I can restore TF2, and press my hotkey again all I want (with the desired effect), and TF2 will remain focused. At any rate, I'm looking for a way to fix this. I've found a lot of questions here covering similar problems, but all of them are related to creating/launching a new form, not making an existing one visible (unless I missed something). I could rework the application to create a new form every time I need one, but that would entail creating yet another form to be invisible all the time just to wait for hotkey events, so I'd rather leave it as it is. Any ideas?

    Read the article

  • Sphere Texture Mapping shows visible seams

    - by AvengerDr
    As you can see from the above picture there is a visible seam in the texture mapping. The underlying mesh is a geosphere based on octahedron subdivisions. On that particular latitude, vertices have been duplicated. However there still is a visible seam. Here is how I calculate the UV coordinates: float longitude = (float)Math.Atan2(normal.X, -normal.Z); float latitude = (float)Math.Acos(normal.Y); float u = (float)(longitude / (Math.PI * 2.0) + 0.5); float v = (float)(latitude / Math.PI); Is this a problem in the coordinates or a mipmapping issue?

    Read the article

  • Only draw visible objects to the camera in 2D

    - by Deukalion
    I have Map, each map has an array of Ground, each Ground consists of an array of VertexPositionTexture and a texture name reference so it renders a texture at these points (as a shape through triangulation). Now when I render my map I only want to get a list of all objects that are visible in the camera. (So I won't loop through more than I have to) Structs: public struct Map { public Ground[] Ground { get; set; } } public struct Ground { public int[] Indexes { get; set; } public VertexPositionNormalTexture[] Points { get; set; } public Vector3 TopLeft { get; set; } public Vector3 TopRight { get; set; } public Vector3 BottomLeft { get; set; } public Vector3 BottomRight { get; set; } } public struct RenderBoundaries<T> { public BoundingBox Box; public T Items; } when I load a map: foreach (Ground ground in CurrentMap.Ground) { Boundaries.Add(new RenderBoundaries<Ground>() { Box = BoundingBox.CreateFromPoints(new Vector3[] { ground.TopLeft, ground.TopRight, ground.BottomLeft, ground.BottomRight }), Items = ground }); } TopLeft, TopRight, BottomLeft, BottomRight are simply the locations of each corner that the shape make. A rectangle. When I try to loop through only the objects that are visible I do this in my Draw method: public int Draw(GraphicsDevice device, ICamera camera) { BoundingFrustum frustum = new BoundingFrustum(camera.View * camera.Projection); // Visible count int count = 0; EffectTexture.World = camera.World; EffectTexture.View = camera.View; EffectTexture.Projection = camera.Projection; foreach (EffectPass pass in EffectTexture.CurrentTechnique.Passes) { pass.Apply(); foreach (RenderBoundaries<Ground> render in Boundaries.Where(m => frustum.Contains(m.Box) != ContainmentType.Disjoint)) { // Draw ground count++; } } return count; } When I try adding just one ground, then moving the camera so the ground is out of frame it still returns 1 which means it still gets draw even though it's not within the camera's view. Am I doing something or wrong or can it be because of my Camera? Any ideas why it doesn't work?

    Read the article

  • How can I cull non-visible isometric tiles?

    - by james
    I have a problem which I am struggling to solve. I have a large map of around 100x100 tiles which form an isometric map. The user is able to move the map around by dragging the mouse. I am trying to optimize my game only to draw the visible tiles. So far my code is like this. It appears to be ok in the x direction, but as soon as one tile goes completely above the top of the screen, the entire column disappears. I am not sure how to detect that all of the tiles in a particular column are outside the visible region. double maxTilesX = widthOfScreen/ halfTileWidth + 4; double maxTilesY = heightOfScreen/ halfTileHeight + 4; int rowStart = Math.max(0,( -xOffset / halfTileWidth)) ; int colStart = Math.max(0,( -yOffset / halfTileHeight)); rowEnd = (int) Math.min(mapSize, rowStart + maxTilesX); colEnd = (int) Math.min(mapSize, colStart + maxTilesY); EDIT - I think I have solved my problem, but perhaps not in a very efficient way. I have taken the center of the screen coordinates, determined which tile this corresponds to by converting the coordinates into cartesian format. I then update the entire box around the screen.

    Read the article

  • Adjust sprite bounds of the visible part of texture

    - by Crazy D0G
    Is there any way to adjust the boundaries of the visible part of the sprite? To make it easier to understand: I have a texture, such as shown at figure 1. Then I break it into pieces and fill the resulting fragments using PRKit (wood texture on figure 2 and 3). But the resulting fragments have the transparent (green color on figure 2 and 3) and when creating a sprite from the fragments they have the size of the initial texture. Is there a way to get rid of this transparency and to adjust the size of the visible part (wood texture), openGL or cocos2d-x means? Maybe it help - draw() method from PRKit: void PRFilledPolygon::draw() { //CCNode::draw(); glDisableClientState(GL_COLOR_ARRAY); // we have a pointer to vertex points so enable client state glBindTexture(GL_TEXTURE_2D, texture->getName()); glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_ONE_MINUS_SRC_ALPHA); glVertexPointer(2, GL_FLOAT, 0, areaTrianglePoints); glTexCoordPointer(2, GL_FLOAT, 0, textureCoordinates); glDrawArrays(GL_TRIANGLES, 0, areaTrianglePointCount); glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); //Restore texture matrix and switch back to modelview matrix glEnableClientState(GL_COLOR_ARRAY);}

    Read the article

  • set several menuitems.visible=true (7 replies)

    Hi all,i got menu like this Master Transaksi Karyawan name : mnuKaryawan Penjualan name : mnuJual User name : mnuUser Logout Exit I'm trying to show the mnuKaryawan etc based on user rights... I use database to store the menu name,and the table like this position menu admin mnuKaryawan admin mnuUser user mnuJual How to set the mnuKaryawan etc.visible true ? Thanks a lot....

    Read the article

  • menubar visible pipelight on secondray screen

    - by Adrien
    First of all, here is my setup : Ubuntu 13.04 on a laptop, main display is the laptop screen, secondary display is my tv Chrome Pipelight (microsoft silverlight running through wine) a silverlight application in the secondary display(netflix) The problem is that, when i put netflix in fullscreen mode, the menubar remains visible on top of the secondary screen. Apparently the aplication that has focus is Microsoft Silverlight. What can I do to solve this?

    Read the article

  • set several menuitems.visible=true (7 replies)

    Hi all,i got menu like this Master Transaksi Karyawan name : mnuKaryawan Penjualan name : mnuJual User name : mnuUser Logout Exit I'm trying to show the mnuKaryawan etc based on user rights... I use database to store the menu name,and the table like this position menu admin mnuKaryawan admin mnuUser user mnuJual How to set the mnuKaryawan etc.visible true ? Thanks a lot....

    Read the article

1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >