orientation-changes

Switching page orientation in ireport

房东的猫 提交于 2019-12-01 06:44:43
I've read there's no way to handle mixed orientations natively using iReport, however reading the documentation I wonder if by using JRDefaultScriptlet's beforePageInit() it could be accomplished somehow. In my case there's a portrait front page, as many landscape pages as there's data to populate them, and a last frontal page. On the other hand does anybody know: If this is a feature to be supported in the near future If there's an alternative that does as requested and generates a jasper-compliant xml file Thanks in advance. So I decided to play around with iReport and see what options there

Switching page orientation in ireport

你。 提交于 2019-12-01 04:18:58
问题 I've read there's no way to handle mixed orientations natively using iReport, however reading the documentation I wonder if by using JRDefaultScriptlet's beforePageInit() it could be accomplished somehow. In my case there's a portrait front page, as many landscape pages as there's data to populate them, and a last frontal page. On the other hand does anybody know: If this is a feature to be supported in the near future If there's an alternative that does as requested and generates a jasper

Saving some data on orientation change in Android

这一生的挚爱 提交于 2019-11-30 20:58:47
As far as I've understood, your Android activity will be recreated for the new orientation on any orientation changes. Is there a way to store / save some of the data from the original orientation upon the orientation change? I'd like to store some Bitmaps, so I don't have to load it again on the orientation change. Using static variables/classes is a bad approach in terms of maintainability and debugging. I have been using Activity.onRetainNonConfigurationInstance but I found out just now that this is deprecated (probably since honeycomb or later). Activity.onRetainNonConfigurationInstance

Android: Efficient Screen Rotation Handling

泄露秘密 提交于 2019-11-30 19:48:45
In Android, when the screen orientation changes (between landscape and portrait) the onCreate method is called which ,if not handled properly, will recreate the entire activity when the result is too simply change the layout and retain all of the same information. I know of a few ways to solve this, but I'm interested in the most efficient way. 1) Telling the manifest that I will handle the orientation change by overriding the onConfigurationChanged() method and leaving it empty. 2) override onSaveInstanceState() and save the data here to be repopulated in onCreate() 3) Override onPause()

Handle states of orientation changes

寵の児 提交于 2019-11-30 19:29:58
问题 How can I handle all states of orientation event occurs? Something like: before starting (save some screen states) when happening (animation purposes) after it's happen (load the screen state) I know that onConfigurationChanged can handle orientation changes. And I tried this: public void onConfigurationChanged(Configuration cfg) { saveState(); super.onConfigurationChanged(cfg); loadState(); } On saveState I store the lastIndex viewed on the Gallery on SharedPreferences. On loadState I get

iOS CAlayer Orientation AVCaptureVideoPreviewLayer doesn't rotate

我是研究僧i 提交于 2019-11-30 11:10:00
问题 Summary: I can't force the CALayer to respond correctly to orientation changes. Whenever I try to use cgaffinetransform I am getting weird results (layer is not centered). Any help will be appreciated! thanks, Process I am adding a preview of video using AVCaptureVideoPreviewLayer subclass. When device is in a portrait orientation everything looks fine. The problem appears when device is rotated to landscape orientation (left or right) or portrait upside down. I am adding a preview of video

Android: Efficient Screen Rotation Handling

99封情书 提交于 2019-11-30 04:21:01
问题 In Android, when the screen orientation changes (between landscape and portrait) the onCreate method is called which ,if not handled properly, will recreate the entire activity when the result is too simply change the layout and retain all of the same information. I know of a few ways to solve this, but I'm interested in the most efficient way. 1) Telling the manifest that I will handle the orientation change by overriding the onConfigurationChanged() method and leaving it empty. 2) override

How to get getIntent() to return null after Activity called with an Intent set

纵然是瞬间 提交于 2019-11-30 02:53:16
问题 This question was similar to my original question, but I think there is a better way to approach a solution. getIntent returns wrong intent when setIntent is followed by a rotation Basically, in my main Activity , which extends FragmentActivity , there are two instances where in a Fragment I pass an Intent to this Activity. This is the code that is having the problem: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(...); if (getIntent() !=

iOS CAlayer Orientation AVCaptureVideoPreviewLayer doesn't rotate

折月煮酒 提交于 2019-11-29 23:22:27
Summary: I can't force the CALayer to respond correctly to orientation changes. Whenever I try to use cgaffinetransform I am getting weird results (layer is not centered). Any help will be appreciated! thanks, Process I am adding a preview of video using AVCaptureVideoPreviewLayer subclass. When device is in a portrait orientation everything looks fine. The problem appears when device is rotated to landscape orientation (left or right) or portrait upside down. I am adding a preview of video using AVCaptureVideoPreviewLayer subclass. When device is in a portrait orientation everything looks

Assigning Fragments to tabs in the ActionBar with different orientations

送分小仙女□ 提交于 2019-11-29 20:59:29
I have 3 fragments and an activity. I want to enable tabs on the ActionBar and assign a Fragment to each of the 3 tabs. How do I hook that up correctly? ORIGINAL POST I have an app that I'm developing using the Google I/O app as a guide. I've implemented tabs into the ActionBar . They seem to be working until the tablet's orientation changes. For example, all 3 tabs have a Fragment . I can switch between them just fine, but when I change the orientation, whatever the Fragment I was last viewing stays visible, but clicking the tabs no longer changes the view... like they have become